Jump to content

dgoosens

Members
  • Posts

    230
  • Joined

  • Last visited

Everything posted by dgoosens

  1. I see you are writing your JavaScript from scratch... This is... well... a little crazy... as each browser has its particularities... Why don't you use something like jQuery ?? All these problems have been taken care of by real smart people... http://www.jquery.com
  2. make sure you replace the instances of "field1" with the column titles of your DB (INDEX_ID & MODEL). Also, you might want to pass the ID into the form echo "<option value=\"" . $row['INDEX_ID'] . "\">" . $row['MODEL'] . "</option>" . PHP_EOL;
  3. hi, the netbeans team is working on the line wrapping http://blogs.sun.com/netbeansphp/entry/line_wrapping_in_dev_builds It works, but it might be unstable from time to time... About the theme... Can't really help... The Ubuntu integration I am using suits me quite well and I never looked into changing it.
  4. Could you be a little more specific about your fields of interest ? Also, try to have a look at all the blogs of people that often contain very valuable info...
  5. here is the code that has been cleaned up: <?php //Type the receiever's e-mail address $emailAddress = "dr@danielreedphotography.com"; //Type your Site Name $siteName = "Daniel Reed Photography"; $contact_name = $_POST['name']; $contact_email = $_POST['email']; $contact_subject = $_POST['subject']; $contact_message = $_POST['message']; if( $contact_name = true ) { $sender = $contact_email; $receiver = $emailAddress; $client_ip = $_SERVER['REMOTE_ADDR']; $email_body = "The Name Of The Sender: $contact_name \nEmail: $sender \n\nSubject: $contact_subject\n\nMessage: \n\n$contact_message \n\n IP ADDRESS: $client_ip \n\n$siteName"; $emailAutoReply = "Hi $contact_name, \n\n We have just received your E-Mail. We will get in touch in a few days. Thank you! \n\n $siteName "; $extra = "From: $sender\r\n" . "Reply-To: $sender \r\n" . "X-Mailer: PHP/" . phpversion(); $autoReply = "From: $receiver\r\n" . "Reply-To: $receiver \r\n" . "X-Mailer: PHP/" . phpversion(); mail( $sender, "Auto Reply: $contact_subject", $emailAutoReply, $autoReply ); if( mail( $receiver, "New E-Mail - $contact_subject", $email_body, $extra ) ) { echo "success=yes"; } else { echo "success=no"; } } ?> if by saying there were two = signs in this line: if( $contact_name = true ) { then you should have left it... One equal sign, in PHP, attributes the value on the right to the variable on the left of it So it probably should be if( $contact_name == true ) { You need to make sure that the fields in your contact name are subject and message maybe you could do a var_dump($_POST); then you'll be able to see the names of the variables
  6. you might want to cleanup your code when posting it on a forum... this is not easy to read. also, could you please post the contact form script (cleaned up...)
  7. ok... nice... cuz I did not really know what to answer anymore... by the way, you should consider working with the mysqli extension...
  8. could you give this a try: $sql="INSERT INTO tb_rss (title, desc, link, date) VALUES('" . mysql_real_escape_string($item['title']) . "', '" . mysql_real_escape_string($item['desc']). "', '" . mysql_real_escape_string($item['link']). "', '" . mysql_real_escape_string($item['date']). "')";
  9. Still the same error. could you post your new script ?
  10. try with something like this VALUES(" . mysql_real_escape_string($item['title']) . ", " . mysql_real_escape_string($item['title']). ", " etc.
  11. the error you are getting makes me think you have quotation marks within the values you are trying to put into your DB. Goalkeeper Scott Cars' You should escape these...
  12. notice that I put $item['title'] not $item[title]
  13. this part is not correct: ($item => title), $item => desc, $item => link, $item => date) should be $item['title'] etc.
  14. This depends on the table and its collation: http://dev.mysql.com/doc/refman/5.0/en/case-sensitivity.html
  15. have a look at regular expressions http://dev.mysql.com/doc/refman/5.1/en/regexp.html something like: SELECT column FROM table WHERE column REGEXP '^[[:alpha:]]'
  16. I'd go for a third table: BILLING_ADDRESSES id | customer_id | billing_address_id id is a simple auto-increment customer_id should be UNIQUE billing_address_id is the id of the address this really seems the simplest and most "elegant" solution to me
  17. You should pay attention with this kind of info: $connection = mysql_connect('127.0.0.1', 'vale_view', '8hw9er1' ); Everybody will be able access your DB now...
  18. something like this ? SELECT job.id, jobtext, jobdate, category.name as catName, author.name as authorName FROM job LEFT JOIN author ON author.id = job.authorid LEFT JOIN jobcategory ON ( jobcategory.jobid = job.id ) LEFT JOIN category ON ( jobcategory.categoryid = category.id ) pay attention when joining different tables that have columns with same name...
  19. this: <input type="checkbox" name="green_leaf" value="<?php if(isset($_POST['green_leaf'])) {echo 'checked="checked"';} ?>" > green does not seem right It should be: <input type="checkbox" name="green_leaf" value="1" <?php if(isset($_POST['green_leaf'])) {echo 'checked="checked"';} ?> > green
  20. Ok... So I did a little research and came across this site: http://verens.com/2006/05/05/some-utf8-problems-and-solutions/ Where it says: Could you give it a try with the mysqli functions ?
  21. this should be rather easy with PHPExcel: http://phpexcel.codeplex.com/ read through the well written and clear documentation (takes half an hour) http://phpexcel.codeplex.com/documentation
  22. hi, I notice you are getting the data from a CSV file... You should make sure that it is Unicode encoded as well... Pay attention, if you are working with Excel... Choose the correct file format.
  23. we would really need to know what your code is doing... could you post the relevant scripts ? thanks, dGo
×
×
  • 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.