AyKay47
Members-
Posts
3,281 -
Joined
-
Last visited
-
Days Won
1
Everything posted by AyKay47
-
no what do you mean by this?
-
well you have your form target set to blank, i would recommend getting rid of it so the form always opens in the same tab.. keeping the target blank and changing it upon $_POST['agents'] == "none" would require some JavaScript integration.. we can go that route if you want..
-
if this is user a user reliant address, it will greatly depend on how they input the data.. no errors are received here?
-
nice, please mark as solved, button on button of page
-
if ($_POST['agents']=="none"){ $last_page = $_SERVER['HTTP_REFERER']; header("Location: $last_page"); }
-
you'll want to exit() after the header as well to prevent the rest of the code form executing..
-
the notice will not affect your code in this case.. your index should be $id_nastavnik = $_POST['del']; instead of $id_nastavnik = $_POST[del]; notice that "del" needs to be wrapped in quotes.. however the parser assumes this so it will not affect your code.. no other errors received? try outputting $sql to see if your sql statement is what you expect..
-
edit to the code above, just realized that I have two x coordinates by mistake in the isset() statement.. should be if(isset($_POST['submit_x']) || isset($_POST['submit_y'])) { }
-
where is your form here? the short sweet way to allow for multiple image upload is to have multiple file type inputs in a form..
-
the name of your image input is "submit" not "OCE", so you must use $_POST['submit'] not $_POST['OCE'] to check for the click event on the image.. you will want something like this.. if(isset($_POST['submit_x']) || isset($_POST['submit_x'])) { }
-
Where do you establish your mysql server connection? Where do you set a value for $delete? If delete is supposed to be the submit button, which I assume it is, you will want to set $delete = $_POST['delete']; first, then change your if condition to if(isset($delete)) { } Avoid using PHP short tags..
-
really depends on what your conditions for joining theses two tables are.. perhaps if you have a join query started we can help you clean up the code..
-
with an image input type.. you will want to check the x and y coordinates to check if the button has been clicked.. $_POST['submit_x']; $_POST['submit_y'] can we also see the PHP code that handles your form
-
Update one record depending on who's logged in?
AyKay47 replied to doomdude's topic in PHP Coding Help
well the while loop technically should work also, your main issue was your form, and not including the PHP correctly.. a while loop is a loop, thus it is designed to loop through more then one instance of data.. your query is meant to only grab one row, not multiple rows, so there is no need to loop through one row.. which is why a simple if statement will suffice here.. -
Update one record depending on who's logged in?
AyKay47 replied to doomdude's topic in PHP Coding Help
in your form you are not including the php into the html markup the correct way...you will want this instead.. <form action="update.php" method="post"> <input type="hidden" name="Memberid" value="<?php echo $row['Memberid']; ?>"> <input type="submit" name="submit" value="submit"> </form> if you are expecting one row to be grabbed from the db using your query, which in this case it should be.. you will want to use an if statement here instead of a while loop.. include the form in your if statement so the $row['Memberid'] variable is valid -
unserialize it, search for the specific value in the array.. display it..
-
Lengthening session with htaccess and php_value?
AyKay47 replied to Someone2's topic in PHP Coding Help
typically you will want to create a php.ini file that mimics the server php.ini file.. then tweak the directives that you would like to change.. -
do you have any code to show us?
-
as pikachu stated, this setting is found in your php.ini file.. you will want to look for the directive labeled "short_open_tag" and set it to "on".. not trying to be an echo to pikachu here, however in the future the short_tag directive will most likely be removed.. I would speak to the owner of the site to have the short tags changed to full tags... using short tags these days is considered a bad practice..
-
Lengthening session with htaccess and php_value?
AyKay47 replied to Someone2's topic in PHP Coding Help
not an expert on .htaccess, however I will take more of a PHP approach.. not knowing what the restrictions set on your domains are, its hard to say if this will work.. but have you tried using ini_set to change the values of the php.ini file.. or perhaps made a custom php.ini in your root directory? -
found some examples on google.. http://www.google.com/#hl=en&sugexp=pfwc&cp=14&gs_id=1d&xhr=t&q=php+countdown+timer&pf=p&sclient=psy-ab&source=hp&pbx=1&oq=php+countdown+&aq=0&aqi=g4&aql=f&gs_sm=&gs_upl=&bav=on.2,or.r_gc.r_pw.&fp=94458c7d4a23e13a&biw=1920&bih=1019 once you learn the basics, adding in the timer stops etc.. should be simple if conditionals..
-
this page has a pretty nice compilation of data about different sql implementations.. http://troels.arvin.dk/db/rdbms/
-
do you have any code at all? you can most likely google this topic and find may results..
-
tabs can really be done with some CSS and javascript.. you can also look at the jquery tabs widget as an idea.. or even to use it.
-
you are setting the value of $roomid to itself.. doesn't make sense.. you set the value of $roomid to the POST data where you use it as your value.. im not understanding.. there will need to be another place where you set your input value to an actual value