<?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>get image source | Student Projects</title>
	<atom:link href="https://studentprojects.in/tag/get-image-source/feed/" rel="self" type="application/rss+xml" />
	<link>https://studentprojects.in</link>
	<description>Microcontroller projects, Circuit Diagrams, Project Ideas</description>
	<lastBuildDate>Sat, 10 Dec 2022 05:31:35 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.1.7</generator>
	<item>
		<title>How to get image source from file using PHP</title>
		<link>https://studentprojects.in/software-development/php-mysql/php-tutorial/image-source-file-php/</link>
					<comments>https://studentprojects.in/software-development/php-mysql/php-tutorial/image-source-file-php/#comments</comments>
		
		<dc:creator><![CDATA[Editorial Team]]></dc:creator>
		<pubDate>Wed, 31 Aug 2011 17:46:31 +0000</pubDate>
				<category><![CDATA[PHP Tutorial]]></category>
		<category><![CDATA[get image source]]></category>
		<category><![CDATA[php script]]></category>
		<category><![CDATA[get img src]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=1782</guid>

					<description><![CDATA[<p>Use preg_match_all to get the image source from your file. PHP code: In the above code variable $content will have the complete source code. Searching the first image using preg_match_all Output: http:studentprojects.in/favicon.ico</p>
<p>The post <a href="https://studentprojects.in/software-development/php-mysql/php-tutorial/image-source-file-php/">How to get image source from file using PHP</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>Use preg_match_all to get the image source from your file.</p>
<p><strong>PHP code:</strong></p>
<pre lang="php" escaped="true" line="1">
<?php 
	$content='Lorem Ipsum is simply dummy text of the printing and typesetting industry. 
        Lorem Ipsum has been the industrys standard dummy text ever since the 1500s, 
        when an unknown printer took a galley of type and scrambled it to make a type specimen book.
        <a href="/"><img decoding="async" alt="" id="logo" src="http:studentprojects.in/favicon.ico"></a>';
        $frst_image = preg_match_all( '|<img.*?src=[\'"](.*?)[\'"].*?>|i', $content, $matches );
	echo $item['image'] = $matches[ 1 ][ 0 ];
?>
</pre>
<p>In the above code variable $content will have the complete source code. Searching the first image using preg_match_all </p>
<p><strong>Output:</strong></p>
<pre lang="html" escaped="true" line="1">
http:studentprojects.in/favicon.ico
</pre><p>The post <a href="https://studentprojects.in/software-development/php-mysql/php-tutorial/image-source-file-php/">How to get image source from file using PHP</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://studentprojects.in/software-development/php-mysql/php-tutorial/image-source-file-php/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
	</channel>
</rss>
