Jump to content

severndigital

Members
  • Posts

    355
  • Joined

  • Last visited

Everything posted by severndigital

  1. you will definatly want to stick with imagik for this type of stuff. i have found it easiest to take one of the pics into photoshop and make all adjustments / additions i want noting what tools, filters, etc.. were used. then replicate these steps through imagick. Color correcting is a very subjective thing though. Unless the photos are taken the same way with the same incorrect lighting, the adjustments would be different for each photo.
  2. you got a whole lot of different questions that deal with as many subjects. you might get better help with these if you ask them one at time
  3. improve them in what way? Unfortunately contrary to its name imagemagik is not magic ...
  4. are you sure .... according to your first question you want to compare and array to a value which question are you trying to answer? is the value of $gor[some] in the array $array or does $array have the same values in it as the array $gor?
  5. try using !empty($_GET['img1']) //instead of isset($_GET['img1']);
  6. ok .. that's a bit different that your first question. how are the arrays getting into this script? if they are separate arrays you will have to hard code each loop for each array.
  7. ok ... bear with me ..now i am confused. are you matching $gor[some] to mutiple arrays?
  8. Ok .. so if understand right, you don't really have to use a loop for this although you could. you can use http://us2.php.net/manual/en/function.array-keys.php array_keys() but you need to put the optional param in. it would look something like this. $locationInArray = array_keys($array,$gor[some]); //this will return all the keys in the array that match $gor[some] I am still a bit unclear about what you want to have happen after the comparison is finished, but that could be my fault, it is quite early in the morning here
  9. hmmmm ... this should maybe be moved to javascript or ajax forum. it will look much better if done using one of those two technologies, and you don't have to worry about the form being reset each time the page is loaded again. This one is a bit more complicated that a few posts. do a google search for Dynamic Form Fields, there are a ton of tutorials on this out with code you can just swipe and start using. I just did the search and the top one should get you what you need.
  10. http://us2.php.net/manual/en/ref.filesystem.php specifically fopen() fwrite() fclose() if I am understanding what you need to do correctly.
  11. you will have to associate the two tables in some way. IMO the best would be in MySQL by adding another field to the db2 referencing the id of the greeting in db1. This is the most dynamic way since then all you need to do to add another greeting is to add it to db1 and update db2 new field with the id. the you would pull the info in a join statement.
  12. are you just trying to find out if $gor[some] is in $array? can you explain what the end goal of the loop will be? There are several ways easy to loop through that array, but each can have a different end result.
  13. yeah ... i think so too, .lol. I am going to start over from scratch (yay for virtual machines and snapshots.) and go through everything again
  14. looking at the bottom of the php.net page http://us2.php.net/manual/en/function.natcasesort.php (the way bottom... in the notes.) looks like this is a common problem. as is the problems with looping through the results of the sorted array.
  15. ok so .. i'll show you where to add it and then i'll comment. you will have to do this in each one. $array = "SELECT stock_id FROM stocks WHERE stock_id BETWEEN '1' and '5' "; $res = mysql_query($array); $count = 0; while ($row = mysql_fetch_assoc($res)){ if (is_int($count / 10) || $count == 0){ $rand_low = rand(1,5); $rand_high = rand(1,5); } $num = rand($rand_low,$rand_high); //add here $update1 = "UPDATE stocks SET y_val=t_val WHERE stock_id='" . $row['stock_id'] ."'"; $update = "UPDATE stocks SET t_val=$num WHERE stock_id='" . $row['stock_id'] ."'"; if (mysql_query($update)){ echo "Updated record(s)<br />\n"; } } ok .. now i'll comment. if there is one thing i have learned over the years.... if you are writing the same code 8 times, there is a better way. this code could be stripped down to at the most 1 of those 8 calls, just by using arrays and a for loop. anyways, it's cool if the code works, just go with it... but if you need to start modifying all these query's over and over again, it would really help you to learn about arrays and for loops at the least. I'm not hating, just trying to help out. C
  16. are you sure all your div tags are closed properly?
  17. still no dice... i took this code directly from the php.net page for ssh2_fetch_stream $conn = ssh2_connect($this->_host); ssh2_auth_password($conn,$this->_user,$this->_pass)or die("Cannot Connect"); //build command line to include this jobnumber //$command = '/usr/local/bin/invoiced_date.sh ' . $jobnumber; $stdout_stream = ssh2_exec($conn, "ls"); $err_stream = ssh2_fetch_stream($stdout_stream, SSH2_STREAM_STDERR); $dio_stream = ssh2_fetch_stream($stdout_stream, SSH2_STREAM_STDIO); stream_set_blocking($err_stream, true); stream_set_blocking($dio_stream, true); $result_err = stream_get_contents($err_stream); $result_dio = stream_get_contents($dio_stream); echo 'Error gets: ' . $result_err; echo '<br/>'; echo 'Dio gets: ' . $result_dio; i removed my .sh script from the mix and am I just running an ls, and it comes still comes back blank. another thing that interesting is that the .sh script is actually running (it does what it is supposed to on the server i am ssh'ing to) I just can't get the variable to fill with output, which is what i need)
  18. What happens if you log in using IE and then when it craps out, manually type in the address of the place you want to go? if you use the same tab, it should keep your session active. if this works, it's something in the code bugging out IE (what a surprise right), if it does the same thing, then it's gotta be something with the forwarding.
  19. UPDATE stocks SET y_val = t_val, t_val=$num WHERE stock_id='" . $row['stock_id'] ."'"; should do it should really be in the MySQL forum though, but it's cool
  20. //add them together: $newstring = $string1 . $string2; //no space between $newstring = $string1 . " " . $string2; //with space between to check the string length you would use strlen(); http://us.php.net/manual/en/function.strlen.php
  21. i normally don't do this .. but .. http://tinyurl.com/nmo72c
  22. How is the ROOT_URL constant being set? you could maybe code around with using the $_SERVER['HTTP_HOST'] instead.
×
×
  • 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.