<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
	<channel>
		<title><![CDATA[Latest posts for the topic "Advance Poll calls from an function generates Database Error"]]></title>
		<link>https://proxy2.de/forum/posts/list/3.php</link>
		<description><![CDATA[Latest messages posted in the topic "Advance Poll calls from an function generates Database Error"]]></description>
		<generator>JForum - http://www.jforum.net</generator>
			<item>
				<title>Advance Poll calls from an function generates Database Error</title>
				<description><![CDATA[ I've tried the sample code:<br /> <br /> [code]<br /> &lt;?php<br /> // Important! You have to include it before your html code<br /> include_once &quot;/var/www/html/poll/poll_cookie.php&quot;;<br /> ?&gt;<br /> <br /> &lt;html&gt;<br /> &lt;body&gt;<br /> &lt;?php<br /> include_once &quot;/var/www/html/poll/booth.php&quot;;<br /> echo $php_poll-&gt;poll_process&#40;4&#41;;<br /> ?&gt;<br /> &lt;/body&gt;<br /> &lt;/html&gt;<br /> [/code]<br /> <br /> And it works fine, but when I'm trying to put then include booth.php and echo $php_poll-&gt;poll_process(4) in a function like this:<br /> <br /> [code]<br /> &lt;?php<br /> // Important! You have to include it before your html code<br /> include_once &quot;/var/www/html/poll/poll_cookie.php&quot;;<br /> <br /> function test&#40;&#41;&#123;<br />    include_once &quot;/var/www/html/poll/booth.php&quot;;<br />    echo $php_poll-&gt;poll_process&#40;4&#41;;<br /> &#125;<br /> ?&gt;<br /> <br /> &lt;html&gt;<br /> &lt;body&gt;<br /> &lt;?php<br />  test&#40;&#41;;<br /> ?&gt;<br /> &lt;/body&gt;<br /> &lt;/html&gt;<br /> [/code]<br /> <br /> I get an error: Database Error, 1046 No Database Selected.<br /> What do I need to do to get this working?]]></description>
				<guid isPermaLink="true">https://proxy2.de/forum/posts/preList/1658/4089.php</guid>
				<link>https://proxy2.de/forum/posts/preList/1658/4089.php</link>
				<pubDate><![CDATA[Fri, 28 Feb 2003 11:01:15]]> GMT</pubDate>
				<author><![CDATA[ Anonymous]]></author>
			</item>
			<item>
				<title>function</title>
				<description><![CDATA[ use this code<br /> [code]<br /> <br /> &lt;?php<br /> // Important! You have to include it before your html code<br />         include_once &quot;./poll/poll_cookie.php&quot;;<br />         include_once &quot;./poll/booth.php&quot;;<br /> <br /> function test1&#40;&#41;&#123;<br />         global $php_poll;<br />         echo $php_poll-&gt;poll_process&#40;4&#41;;<br /> &#125;<br /> <br /> echo &quot;&lt;html&gt;&lt;body&gt;&quot;;<br /> test&#40;&#41;;<br /> <br /> echo &quot;&lt;/body&gt;&lt;/html&gt;&quot;;<br /> ?&gt;<br /> [/code]]]></description>
				<guid isPermaLink="true">https://proxy2.de/forum/posts/preList/1658/4099.php</guid>
				<link>https://proxy2.de/forum/posts/preList/1658/4099.php</link>
				<pubDate><![CDATA[Fri, 28 Feb 2003 15:24:41]]> GMT</pubDate>
				<author><![CDATA[ Anonymous]]></author>
			</item>
	</channel>
</rss>