Jump to content

ToonMariner

Members
  • Posts

    3,342
  • Joined

  • Last visited

Everything posted by ToonMariner

  1. not until you show us some code. we would need the actual ajax request, the code called by the ajax request and the ajax response code...
  2. border-collapse: collapse put that in your css properties for th table.
  3. <?php function checkStr($str,$charArr) { //checks if chars of str are within charArr, returns true if it checks, false if it doesn't $flag = true; $x = 0; do { if (!in_array(strtolower($str{$x}),$charArr)) { $flag = false; echo $str{$x}; break; } $x++; } while($x < strlen($str)); return $flag; } $str = '133444444444444444444444444444444444'; if (checkStr($str,array('1','2','3','4'))) { echo 'yes'; } else { echo 'no'; } ?> a slight;ly more elegant soluntion IMO...
  4. exec('/usr/bin/sox 20071120-014450.ogg -e stat',$p); print_r($p); try that
  5. can't find anything to do with 3rd party scripts for hotmail, gmail or yahoo!!!
  6. not so sure thorpey - most of these scripts contact the respective mail servers purely via curl and request the information. I may be wrong I have seen one hotmail script and imap is not used anywhere to retrive that users contact list.
  7. $str = preg_replace('/(((ftp|http|https):\/\/)?www\.(.*)+\.(.*)+) /','<a href="$1">$1</a>',$str); try that
  8. Hi guys - an unusual one for me but does any know of any scripts available for importing contact list from hotmail, gmail etc etc. seen plenty to buy (which I don't mind doing) but need one with source code made available. Alternatively a tutorial detailing what is required to actually contact the servers via curl with the correct parameters.... Many many thanks for any help offered in advance.
  9. if you use a h1 tag it should clear it - if not you can always apply clear: left to your header tags in that div...
  10. the easiest way to achive this would be to have one image that is bigger than you need and simply set it as a background. inorder to make an image as big as the screen you would need some javascript to report the screen size (an ajax request of some sort ) and maintain that databetween requests (a session or cookie) and serve a graphic based on that info. IF you are going to use the latter method I would suggest you simply create a few images to serve as backgrouns rather than generating one dynamically - there is no-need to recreate an image each time and rathaer than cache the php generated image you may as well just create them.
  11. $str = preg_replace('/((ftp|(http(s)?)://)?www\.(.*)+\.(.*)+ /','<a href="$1">$1</a>',$str); try that...
  12. when you upload the image you should check that a file with the same name is not in the same location - if it is you shoudl rename the image that is being uploaded. but back to your specific question - the information about the uploaded file is stored in the $_FILES supre global - you can grab the name of the original from there and add it where ever you like in your database.
  13. xhtml and xml are not the same thing... xhtml is ,if you like, html that can be used as an itegrated wrapper for xml... u is not a valid tag in xhtml as it is a styling tag - you should use css to add text-decoration to span tags to achieve the same style. xml on the otehr hand is a markup designed to hold data. you use it in conjuction with xsl to generate a table structre for the data AND the styling. xhtml need know only the source of the data for the browser to grab the file and start rendering it. In essence the xml data is processed after the page has finished being processed....
  14. avoid using frames - then it will look really professional!
  15. as in you don't set the width at all and it will be as wide as it needs to be.... why set width="1" when it will do the same without any width. Also width is not a valid attribute in strict html - its a styling issue - even then it should NEVER be set.
  16. you should try and avoid fixed heights when possible...
  17. you should look into a flash player solution....
  18. <?php if (strpos($_POST['string'],'www') { echo "Yes they did"; } else { echo "No they didn't"; } ?>
  19. simple answer is yes - long answer is yes but what if the preceeding characters containe the same words you are looking for???? in order to perform waht you want a regular expression is required - and it needs some rules inorder to work properly... IF the code you want stripping won't contain those words then this should do the trick... <?php $DATA = " _SOME OTHER RANDOM DATA_ copyright of me and you 2007 and the others bread 15.22 44.97% crumbs 15.532 6.47% apple 146.932 6.555% coffe 83.72 6.537% thank you all friend and everyone data date and year 2007 _SOME OTHER RANDOM DATA_ "; $str = preg_repace('/(.*)bread(.*)?thank you(.*)/s','bread$2'); ?> have a play with that...
  20. not really - it is good practice to do this kind of thing in your code though - laziness now can result in problems later!!!!!! if you are using multiple connections on a page then you shoudl manage them properly but essentially php runs this command at the end of every page (that is not utilizing mysql_pconnect).
  21. eeeeuuuuuuuccccccchhhhhh can't be bothered to read all that BUT to get the number of pages that your pagination requires you need to divide the total number of items by the number of items per page and round it up.. like so... <?php $pages = ceil($items/$itemsperpage); ?>
  22. a list is better markup for menus (or even definition lists if applicable). not sure what you are trying to achieve so perhaps an example would help...
  23. when you say its not showing up... if you held the mouse button down can you select the stuff??? if so its the 'hasLayOut problem - this page will help with that - http://www.satzansatz.de/cssd/onhavinglayout.html
  24. yep - if you are using js then why not create a div on your page for a dialogue box and simple show/hide it...
×
×
  • 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.