Jump to content

MadTechie

Staff Alumni
  • Posts

    9,409
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by MadTechie

  1. try this "%\[img\](http://.*?(jpg|bmp|gif|jpeg))\[/img\]%s" EDIT opps forgot the s
  2. PHP is the same for all browsers, your need to check javascript and the forms.. as a total guess do a print_r($_POST) at the start and see if anything is missing
  3. try this "|\[img\](http://.*?(jpg|bmp|gif|jpeg))\[/img\]|s" PS wrong section should be in RegEx
  4. SELECT * FROM table WHERE field LIKE '%Hello%' % = * (wildcard) is that what your looking for ?
  5. In VB.NET you can use the FileInfo class for the basic info Dim f As New FileInfo("C:\demo.dll") Debug.WriteLine(f.LastWriteTime.ToString) Debug.WriteLine(f.LastAccessTime.ToString) Debug.WriteLine(f.CreationTime.ToString) Debug.WriteLine(f.Name) ETC... as for the assembly attributes (description, version and author) heres a good article, http://www.vbdotnetheaven.com/UploadFile/mpathak/ReadingAssembly04112005053044AM/ReadingAssembly.aspx you could create an ASPX page or ActiveX object or even have a small moniting app running on a windows machine creating a text file for each dll with the info you need
  6. check the manual filesystem as for description, version, author their window based resources.. you may get an extension or a file resource parser that will but no builtin functions that i know of (never tried).. a few commands are here fileatime — Gets last access time of file filectime — Gets inode change time of file filegroup — Gets file group filemtime — Gets file modification time fileowner — Gets file owner fileperms — Gets file permissions filesize — Gets file size filetype — Gets file type
  7. have the record ID as a hidden field or something, then when you click the (update/delete) button you can either DELETE FROM table WHERE ID = $id; or UPDATE table SET field1 = '$text1' etc have a go and post back your solution so far if you have problems
  8. i always recommend phpmailer.. is this topic closed now ? if so please click topic solved
  9. PHP can not play WAV files.. you would be better off using Flash or javascript to play them. as for the code supplied it will only work on Netscape, see the javascript section for more info.. as for "Inside the loop it is not working.Why?" its working exactly how its been programmed to work.. please read How To Ask Questions The Smart Way
  10. try this <?php $data = '<form action="form1.asp" method="get"> <input type="text" name="val1"> </form> <form action="form2.asp" method="post"> <input type="text" name="val2"> </form> '; preg_match_all('/(?<=\<form )action="(\w+\.\w+)".*?name="(\w+)"/si', $data, $result, PREG_PATTERN_ORDER); $forms = $result[1]; $values = $result[2]; echo "<pre>"; print_r($forms); print_r($values); echo "or<br />"; $newarray = array(); foreach($forms as $K => $V) { $newarray[] = "$V & {$values[$K]}"; } print_r($newarray); ?>
  11. may, just maybe you should think about learning how to write your own.. heres a starting point php.net/manual/ref.sockets.php OR Pay someone who has taken the time to learn it.. please read the GUIDELINES:
  12. sighs.. that why i have this! $SqlUpdate = "UPDATE cscart_product_prices SET price='$ToPrice' WHERE product_id = '$FromID' AND product_code = '$FromPart'" does the logic the my version make sense to you ?
  13. try this $md5 = md5_file("swf/" . basename($jpg_link)); $link = mysql_connect("host", "user", "passw"); mysql_select_db("database", $link); $SQL = "select count(gId) from games where gSwfFile='$md5.swf';"; $result = mysql_query($SQL) or die(mysql_error()); $dupe = mysql_result($result , 0);
  14. if your trying to pull the file from the allfiles array try this $maximum = 2; $a = (isset($_COOKIE['e']) && intval($_COOKIE['e']) < $maximum)? intval($_COOKIE['e'])+1 : 1; setcookie("e", $a, time()+60*60*24*180); $currentFile = $a; $allfiles = Array(); $allfiles[1] = "thisfile.txt"; $allfiles[2] = "thatfile.html"; $file_content = file_get_contents($allfiles[$currentFile]);
  15. try this $md5 = md5_file("swf/" . basename($jpg_link)); $SQL = "select count(gId) from games where gSwfFile='$md5.swf';"; $result = mysql_query($SQL) or die(mysql_error()); $dupe = mysql_result($result , 0); just broke it down really
  16. their the same page ?
  17. first off $thesefiles = array('something1.txt','another2.txt','3.txt'); will put numbers in as for the example you did, your almost right $thesefiles = Array(); $thesefiles[1] = "something1.txt"; $thesefiles[2] = "another2.txt"; $thesefiles[3] = "3.txt"; useful command is echo "<pre>"; print_r($thesefiles);
  18. $_SESSION['points'] = $row['points']; NOT == apply to all
  19. seams ok, also on all other SQL statements add AND confirmation_field = 'Yes'
  20. if you keep getting that error on startup then it could be a problem with a installed file, maybe a reinstall?
  21. whats the erro ?
  22. whats WHERE cscart_products.product_id = cscart_product_prices.product_id all about ? why do you keep adding that ?
  23. the problem is here userid=$username whats the name of the field in the database that holds the username? find that and change it ie username='$username'
  24. mysql_select_db('czartga_login') or die('Error, cannot select mysql database'); $query="update users set num_clicks=(num_clicks+1) WHERE userid=$uid"; $result=mysql_query($query); Note the userid=$uid your need to change this to suit your script/db
×
×
  • 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.