Jump to content

DwayneB

Members
  • Posts

    3
  • Joined

  • Last visited

DwayneB's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Thanks guys, Your right about the AJAX. I am not sure what I was doing last night. I made things way more complicated then it has to. What I am trying to do is organize products into better categories then they already are. Problem is there is 7000+ products. I have a plug in that will export a csv file of all products, details including location of the img for the product. I want my page to read that file, create a table showing product ID, Name,Description and the image (not the name but the image) as well as a check box for 50 products at a time. I can then place a check in each product that I choose, at bottom of the 50 enter a number representing the ID of the category, hit submit and a mysql or mysqli or PDO commeand would update the database. The hole deal above was; I wanted others to be able to use this, So they should have been able to enter there database information and the button would have been for them to test the connection to the database. I have a better way of accomplishing this task now though!! Thanks everyone.
  2. Ok here it goes guys let me explain what I want to do. I am writing a PHP script built into a HTML file. The page will have a series of tables. The fist table will have be were the user inputs the required information to connect to there mysql database. at the bottom of the table will be a button with the onclick action set to call my php script to connect to the data base. Once connected I want data saying connected successfully or the error messges put into the table data fields marked in red below. Button is in blue. do I put the php script with in the <td> I want the respose to? Making sure it echo's the html tags needed? <tr><td align="right">Database host: </td><td> <input type="text" name="host"/></td></tr> <tr><td align="right">Database name:</td><td> <input type="text" name="dbname"/></tr> <tr><td align="right">Username:</td><td><input type="text" name="username"/></td></tr> <tr><td align="right">Password:</td><td><input type="password" name="password"/></td></tr> <tr><td>out put from the php script that connects to the database and makes sure its connected to the right database</TD</tr> <tr><td><button ---- to call the php function to connect to the data base/></td></tr> This is the code I have now but I'm not sure if this will work. I'm not sure how to reference the data in the input fields, to the peramiters passed to the function. Can someone shed some light?? Thanks <div id="database"> <table border = "1" align="center" cellpadding="10"> <tr> <td align="right">Zen-Cart Database Name:</td><td><input type="text" name="dname" /></td><td align="right" >Database Table Prefix(no spaces):</td><td><input type="text" name="prefix"/></td> </tr> <tr> <td align="Right">Database Username:</td> <td><input type="text" name="Uname"/></td> <td align="right">Password:</td> <td><input type="password" name="pass"/></td> </tr> <tr> <td align="right">Database host:</td><td><input type="text" name="host"/></td> <tr> <?php Function dbconect($host,$dbname,$Un,$pass,) { mysql_connect($host,$Un,$pass) or die (my_err()); echo("<td>Connected to your mysql database!</td>"); mysql_select_db($dbname) or die (mysql_error()); echo('<td>Connected to My Sql database name ' . $dbname . '</td>); } ?> </tr> <tr><td> </td><td colspan="2"><button type="button onclick="dbconnect(host,dname,Uname,pass)">Test Connection</button></td></tr> </table> </div>
  3. Hey guys, I'm new at PHP,mySQL and HTML. Just got out of school for them. A couple companies around me want to make a website for them using PHP and HTMl. I know I can do it, the most complicated thing they want is a login section. Even whats behind the password protected side is easy. My question is, when you guys are doing side job is there a basic rule of thumb for charging people? How do you figure it out? Strictly time? Complication? I know I'm a rookie and all. But I don't want to over charge nor do I want under charge and end up screwing my self for future work. If it matters I'm in the Detroit, mi area. Thanks
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.