Jump to content

newb

Members
  • Posts

    454
  • Joined

  • Last visited

Everything posted by newb

  1. im trying to group by day not month..didnt help
  2. $query = mysql_query("SELECT * FROM av_items ORDER BY av_items.date DESC LIMIT 20"); while ($row = mysql_fetch_assoc($query)) { $id = $row['id']; $date = $row['date']; $message = $row['message']; $entry_date = date("Ymd", $date); if ($entry_date !== $called_date) { echo '<h1 class="topic">'.av_date($date) .'</h1>'; echo $message; $called_date=$entry_date; } }
  3. i am trying to acheive this: http://www.breakfastpolitics.com/ can someone help me out please.. :-\
  4. i dont think that works because in my database there is stored UNIX timestamps...
  5. i have a problem..my posts are showing up like this: July 6: post message July 6: post message July 6: post message im trying to get it like this: July 6: post message post message post message how do i group them like this in all in one post?
  6. ok ive done this, anything else i can improve?
  7. alright, thanks for the info. ive updated the links on my pages
  8. ok so theres no way i can redirect all of the long URL requests to the new SEO URL so theres no duplicate content?
  9. my website URL rewrites arent working properly: SEO URL: http://www.clickrewrite.com/2/1/sports-betting-champ/ Long URL: http://www.clickrewrite.com/index.php?cid=2&p=1&name=sports-betting-champ when i enter the SEO URL in the address directly it works, but the long url doesnt redirect to the shortened SEO friendly URL. i want the long URL to redirect to the SEO URL automatically when entered but it doesnt. how can this be fixed? here is my .htaccess Options +FollowSymLinks -MultiViews RewriteEngine On RewriteRule ^([0-9]+)/([0-9]+)/([a-z-]+)\/$ /index.php?cid=$1&p=$2&name=$3 [NC,L] RewriteRule ^([0-9]+)/([0-9]+)/$ /index.php?cid=$1&p=$2 [NC,L] RewriteRule ^([0-9]+)/$ /index.php?cid=$1 [NC,L] EDIT: also how is it possible for me to replace all the long url links in my source code w/ the new SEO URL links
  10. Any tips on how i can get the search engines to index more of my pages faster? http://www.clickrewrite.com/ its a pr0 site only about a week old.
  11. ok im getting close: the problem is that it is adding +50 on the first value which is 1 (i dont want this) anyway to fix this? i just want it to add +50 to the all the other values except the first so it should be as. 1. +0 2. +50 3. +50 etc etc.
  12. yes the actual numbers would be 1: 50 2: 100 3: 150 4: 200 5: 250 they would just continue to add on
  13. i have a number string which is any random integer of 1-10. how can i make it so that if the string turns out to be 5, there will be 50 added on for every number under it. for example: $string = '5'; 1: +0 2: +50 3: +50 4: +50 5: +50 etc etc.. can anyone help?
  14. how can i check a URL string for "www" and if it doesnt have it how to add it
  15. well ive wrote up something using pspell but its pretty sloppy but it works..its able to split 3 joined words max as thats all i require.. if anyone else thinks they can write something better let me know.. <? $sentence = "laughoutloud"; function extractwords($sentence) { $pspell_link = pspell_new("en_us"); $size = strlen($sentence); for ($i = 0; $i < $size-1; $i++) { $currentword = substr_replace($sentence ,"",($size - $i)); if (pspell_check($pspell_link, $currentword)) { $firstword = $currentword; $remaining = substr($sentence, strlen($firstword)); //echo "currentword:$currentword<br>"; //echo "remaining:$remaining $secword<br>"; break; } } $size = strlen($remaining); for ($i = 0; $i < $size-1; $i++) { $secword = substr_replace($remaining ,"",($size - $i)); if (pspell_check($pspell_link, $secword)) { $secondword = $secword; $thirdword = substr($remaining, strlen($secondword)); //echo "currentword:$currentword<br>"; //echo "remaining:$remaining $secword<br>"; break; } } echo "$firstword<br />"; echo "$secondword<br />"; echo "$thirdword<br />"; } extractwords($sentence); ?>
  16. the compound word strings are from URL names that are joined together for example phpfreaks.com but id like to put a space inbetween 'php' and 'freaks' somehow. also how could i add a dictionary list to the php script..
  17. is it possible to use preg_split to split joined words? such as 'ohmygod'
  18. ok, but the string is always some random combination of joined words like 'ohmygod' and 'laughoutloud' never always the same. however i need the words to be split up not joined. the function you've sent me to says i need to have a set array of words to check against in order for it to work. however, the string could be any combination of joined words. so i think this is no good for me..
  19. something like this: if (preg_match('|<div class="quotationHeaderText">(.*)</div>|U',$html,$result)) { $match = $result[1]; }
  20. another example is: is it possible for php to have something like how google is doing this: http://www.google.com/search?q=sportscar when i enter 'sportscar' in the search it says: did you mean 'sports car' and separates the two words.
  21. how can i split compound words in a random php string for example, i have strings such as $word = 'ohmygod' is it possible for php to detect the individual words as joined together and make them to form: $word = 'oh my god' 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.