Jump to content

QuickOldCar

Staff Alumni
  • Posts

    2,972
  • Joined

  • Last visited

  • Days Won

    28

Everything posted by QuickOldCar

  1. screengrab doesn't work for firefox 9 I use Pearl Crescent Page Saver, install the basic version. Can also set ways to save them, naming,sizes,visible window, entire page,save folder location,etc.
  2. I myself have been waiting for this mysterious php6 version to appear. The main reason is to properly handle unicode and in all languages. There used to be a php6 beta version out there, but now the http://snaps.php.net/ no loger exists. I did try the beta a while back, and yes it had a lot of bugs. According to wikipedia: The development of PHP 6 has been delayed because the developers have decided the current approach to handling of instance unicode is not a good one, and are considering alternate ways in the next version of PHP. The updates that were intended for PHP 6 were added to PHP 5.3.0(namespace support, Late Static Bindings, lambda functions, closures, goto) and 5.4.0(traits, closure rebinding) instead. I think it be easier to create standards over the net that everything must be set to UTF-8 or UTF-16 or their sites won't even display. Possibly even something on the websites server itself to display as UTF-8 before html output. They can access the correct charsets from their servers, unlike someone visiting them. It's been so many years of websites using a language specific character set and the browsers along with applications trying to display them correctly. I just feel that sometimes we gotta let old standards die and make way for newer better methods. So far in my efforts I have been able to get roughly 99% of these charsets properly encoded, but unfortunately..sometimes the wrong, or no charset is set coming from the website itself. That makes for improper coding, not seeing all characters correctly. Just wanted to inform everyone, the reasons that browsers can detect them all...they have made many types of methods to properly check character encoding and to display them. I read an article on it a few years ago. I'm actually amazed the browsers do such a good job. I'm glad in that respect. If anyone has a complete solution for this, would love to hear it. I am speaking of using something like curl in php, and no matter what charset or none, it properly saves every single character as utf-8
  3. Best guess is it needs access to something else as well and can't, thus crashes.
  4. How about a site with people's ideas, similar to what you are asking now. If nothing else, you get some idea's to try.
  5. it's the same as your mysql would be stock mysql usually root for name and no password, but you should create a new admin name for mysql with a password This may be helpful to you http://dev.mysql.com/doc/refman/5.6/en/adding-users.html http://www.cyberciti.biz/faq/mysql-change-root-password/
  6. It's a local business delivering to his town, I doubt doing facebok or the like would help.
  7. I agree with the other posters, ads usually don't cut it, must provide a service and it be good enough for them to pay for it. Usually any of these better ideas take up many resources, lots of space,memory and cpu, or even multiple machines. Those cost serious money and hard to profit from them from the start, so most never venture into them knowing are gonna be in the black. Over my 30 years on the net, I've seen a lot come and go, really cool ideas, but not really profitable.
  8. Instead of all those fwrites, can do heredoc, then write that to a file. Just an example <?php $gametitle = "game name"; $text = <<<EOF <html itemscope itemtype='http://schema.org/Review'> <head> <title> $gametitle Review </title> <Script type='text/Javascript' src='header.js'></Script> <Script type='text/Javascript' src='address.js'></Script> <link rel='stylesheet' type='text/css' href='game.css' /> </head> <body> Here's the $gametitle </body> </html> EOF; echo $text; ?>
  9. I would probably make each retailer their own table, and do a join on the retailers. retailer1 id|item_number|title|description|price|url|timestamp retailer2 id|item_number|title|description|price|url|timestamp retailer3 id|item_number|title|description|price|url|timestamp retailer4 id|item_number|title|description|price|url|timestamp retailer5 id|item_number|title|description|price|url|timestamp so on The reasons being if that retailer left, or added new ones, faster displaying just that retailer, less resources to search one retailers table versus all the retailers, when crawling their sites can do checks if item already exists within just one table versus all, and if does update, else insert new. as for the one big script or individual ones, I'd do one scraper for all, you can list all 15 retailers in a text file list, or in an array. For the initial crawls you can scrape entire sites if wanted, then do one checking for new content, and eventually all their items would get there...while still getting their new content as they added it. Ordinarily scrapers just look for urls, then use curl and grab all the related information on a page,use regex to find the specific content, for this I would say do the single scraper, because in this way could expand to more retailers easily by adding a new name domain in the list, and create new table. But if are doing something like DOM and have to specify the areas to grab content from, I guess each one would have to be a unique crawler. To me whatever works better in accuracy and efficiency is the way to go.
  10. Look what Joel posted, he stated about setting $search as a string, nothing to do with your gametitle. $newstring = '$search = You are making a new variable for $search, then making a new variable of that for $newstring, do what Joel wrote. Posting the entire code would help more.
  11. ajax for some slick dynamic content without refreshing the page (optional) some css style to make it all look pretty
  12. To be honest many of the books , even though they have newer versions, still have old or incorrect practices in them. Most of the time you are just copying chunks of code and they briefly inform you on some of the why, and alternate methods. In general it will be what that author felt it should be. There are a few places to get you started online. http://www.tizag.com/phpT/index.php http://www.w3schools.com/php/ http://devzone.zend.com/6/php-101-php-for-the-absolute-beginner/ http://www.web3mantra.com/2011/06/21/35-best-php-video-tutorials/ And the best place yet, the php manual, usually with some examples and explanations. http://php.net/manual/en/tutorial.php And if ever get stuck with a code, can always drop into phpfreaks for assistance.
  13. I actually prefer this, together with for loops, and the curly bracket on same line. But if I happened to not space it, I wouldn't go back and change it. for($i=0; $i<$count; $i++) { if($i < 10) { echo $i; } }
  14. I believe whitespace is negligible, but lots of comments make a difference. Either way I prefer the uncluttered look, everything together is harder to read.
  15. For the timezone detection, this works well. http://www.onlineaspect.com/2007/06/08/auto-detect-a-time-zone-with-javascript/
  16. Is another thing to consider. The visitors of your site will be on their own times, this script would only do your server time. You would need to use javascript and attempt to detect their location, and use their timezone. If didn't do that it will never be right for many people.
  17. Sorry, forgot you are using mysqli_connect use mysqli_error()
  18. You using phpmyadmin at all?, are the values being stored properly? you can try to echo your $query in your login_url.php to see if it has values, and add mysql_error() to see why your query is failing. it could be a case sensitive issue, use strtolower() on the name and password
  19. There is no $_POST form for that script, unless you want to retrieve from a $_GET some changes <html> <head> <title>Hi User</title> </head> <body> <?php $userName = $_POST['userName']; if (empty($userName)){ print <<<HERE <h1>Hi User</h1> <form action="" method="post"> please enter you name: <input type = "text" name = "userName"> <br> <input type = "submit"> </form> HERE; }else{ print "<h1>Hi There, $userName !</h1>"; }//end ?> </body> </html>
  20. I would probably edit the file to have a php extension. Insead of dbstuff.inc rename to dbstuff.inc.php and edit line 31 in login_url.php to: include("dbstuff.inc.php"); dbstuff.inc.php <?php //edit to your login credentials $host = "localhost"; $user = "mysql admin user name"; $password = "mysql user password"; $database = "your database name"; ?>
  21. There is many types of sorting. Please explain in what way, or in how of the sorting you desire.
  22. you should add the meta description and keywords as well <meta name="description" content="Hertford Logs seasoned firewood for sale in Hertford" /> <meta name="keywords" content="hertford, log, logs, delivery, firewood, seasoned firewood, loose logs, purchase firewood, buy firewood" /> Display business hours, directions, prices?, maybe also an email contact, for hours are not open
  23. http://www.joomlahacks.com/ You can browse my index for others, search joomla help Moving to wordpress is another option.
×
×
  • 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.