<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>JayGilford.com &#187; Common questions</title>
	<atom:link href="http://www.jaygilford.com/category/php/common-questions/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.jaygilford.com</link>
	<description>Numerous articles on PHP, MySQL and Apache files</description>
	<lastBuildDate>Wed, 03 Feb 2010 20:07:47 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Using the PHP Document Object Model (DOM) to get all page links</title>
		<link>http://www.jaygilford.com/php/php-dom-get-all-pagelinks/</link>
		<comments>http://www.jaygilford.com/php/php-dom-get-all-pagelinks/#comments</comments>
		<pubDate>Wed, 27 Jan 2010 16:27:03 +0000</pubDate>
		<dc:creator>Jay</dc:creator>
				<category><![CDATA[Common questions]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Document Object Model]]></category>
		<category><![CDATA[DOM]]></category>
		<category><![CDATA[DOMDocument]]></category>
		<category><![CDATA[Friends]]></category>

		<guid isPermaLink="false">http://www.jaygilford.com/?p=103</guid>
		<description><![CDATA[Further to the article I wrote about parsing links from a html page, here is a more elegant and accurate solution to getting every link using the Document Object Model (DOM)

PHP Code
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
/**
 * @author Jay Gilford
 */
&#160;
/**
 * get_links()
 * 
 * @param string $url
 * @return array
 */
function get_links&#40;$url&#41; &#123;
&#160;
    // [...]]]></description>
		<wfw:commentRss>http://www.jaygilford.com/php/php-dom-get-all-pagelinks/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Number to text converting PHP class</title>
		<link>http://www.jaygilford.com/php/number-to-text-converting-php-class/</link>
		<comments>http://www.jaygilford.com/php/number-to-text-converting-php-class/#comments</comments>
		<pubDate>Mon, 02 Nov 2009 14:19:42 +0000</pubDate>
		<dc:creator>Jay</dc:creator>
				<category><![CDATA[Common questions]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[class]]></category>
		<category><![CDATA[common]]></category>
		<category><![CDATA[numbers]]></category>
		<category><![CDATA[text]]></category>

		<guid isPermaLink="false">http://www.jaygilford.com/?p=89</guid>
		<description><![CDATA[One thing that gets asked quite a bit on forums is how to convert a number into words in PHP, so I thought I&#8217;d write a small class that can do this

Here is the code for the class

PHP Code
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
class num2text &#123;
    private $_original = 0;
    private $_parsed_number_text = '';
 [...]]]></description>
		<wfw:commentRss>http://www.jaygilford.com/php/number-to-text-converting-php-class/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>how to get all links from a web page</title>
		<link>http://www.jaygilford.com/php/common-questions/how-to-get-all-links-from-a-web-page/</link>
		<comments>http://www.jaygilford.com/php/common-questions/how-to-get-all-links-from-a-web-page/#comments</comments>
		<pubDate>Mon, 26 Oct 2009 00:13:46 +0000</pubDate>
		<dc:creator>Jay</dc:creator>
				<category><![CDATA[Common questions]]></category>
		<category><![CDATA[content]]></category>
		<category><![CDATA[Friends]]></category>
		<category><![CDATA[page]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[urls]]></category>

		<guid isPermaLink="false">http://www.jaygilford.com/?p=85</guid>
		<description><![CDATA[A question that gets asked all the time on forums is &#8220;How do I get all links on a web page&#8221; inside of &#60;a&#62; tags, so here&#8217;s some code with full commenting for each line

PHP Code
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
/**
 * @author Jay Gilford
 */
&#160;
// regular expression pattern to match all links on a page
$pattern = '%&#60;a [^&#62;]+href=&#34;(?P&#60;url&#62;[^&#34;]+)&#34;[^&#62;*]*&#62;(?P&#60;text&#62;[^&#60; ]+)&#60;/a&#62;%si';
&#160;
// [...]]]></description>
		<wfw:commentRss>http://www.jaygilford.com/php/common-questions/how-to-get-all-links-from-a-web-page/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
