<?xml version="1.0" encoding="UTF-8" ?>

<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
<channel>
    <title>Posteet: jacinmontava: mysql</title> 
    <link>http://www.posteet.com/</link> 
    <description>Recent posteets posted to Posteet</description>
    <ttl>60</ttl>

    
    <item>
        <title>Extraer un dato de la BD</title>
        <link>http://www.posteet.com/view/627</link>
        <description>
        <![CDATA[<pre>function dime_datos($tabla, $campo, $id_recibida)
{
   $link = conectarse();
   $consulta_sql = &quot;SELECT $campo FROM $tabla WHERE id = '$id_recibida'&quot;;
   $consultar = mysql_query($consulta_sql, $link);
   return mysql_result($consultar, 0);
}</pre> <a href="http://www.posteet.com/tags/mysql">[mysql]</a>  <a href="http://www.posteet.com/tags/php">[php]</a> ]]>        </description>
        <dc:creator>jacinmontava</dc:creator>
        <pubDate>Wed, 26 Dec 2007 15:03:33 +0000</pubDate>

            <category>mysql</category>
            <category>php</category>
    
    </item>

  
    <item>
        <title>Conexion Base de Datos</title>
        <link>http://www.posteet.com/view/623</link>
        <description>
        <![CDATA[<pre>$localhost = &quot;localhost&quot;;
$usuario = &quot;nombre usuario BD&quot;;
$password = &quot;password BD&quot;;
$nombreBD = &quot;nombre BD&quot;

function conectarse()
{
   if (!($link=mysql_connect($localhost,$usuario,$password)))
   {
      echo &quot;Error conectando a la base de datos.&quot;;
      exit();
   }
   if (!mysql_select_db($nombreBD,$link))
   {
      echo &quot;Error seleccionando la base de datos.&quot;;
      exit();
   }
   return $link;
}</pre> <a href="http://www.posteet.com/tags/mysql">[mysql]</a>  <a href="http://www.posteet.com/tags/php">[php]</a> ]]>        </description>
        <dc:creator>jacinmontava</dc:creator>
        <pubDate>Wed, 26 Dec 2007 14:35:53 +0000</pubDate>

            <category>mysql</category>
            <category>php</category>
    
    </item>

  
    <item>
        <title>Recuperar la ultima id insertada</title>
        <link>http://www.posteet.com/view/602</link>
        <description>
        <![CDATA[<pre>mysql_query(&quot;INSERT INTO table (nom_table) values ('ex')&quot;);
   $ultima_id =  mysql_insert_id();
   echo $ultima_id;</pre> <a href="http://www.posteet.com/tags/mysql">[mysql]</a>  <a href="http://www.posteet.com/tags/php">[php]</a> ]]>        </description>
        <dc:creator>jacinmontava</dc:creator>
        <pubDate>Thu, 20 Dec 2007 11:55:09 +0000</pubDate>

            <category>mysql</category>
            <category>php</category>
    
    </item>


</channel>
</rss>
