AyKay47
Members-
Posts
3,281 -
Joined
-
Last visited
-
Days Won
1
Everything posted by AyKay47
-
mysql_fetch_assoc returns an array of data not a string..
-
what is the return set to in your custom function?
-
from the looks of it, you're going to have a fun time at it.. the previous coder doesn't look to have been very efficient.. good luck!
-
question for you.. why did you decide that having comments inside of your element was a good idea? the button values do a good job of indicating what the purpose of the button is, don't you think?
-
short answer. yes. the comments in your buttons are absolutely not needed and should be removed anyhow.
-
np, please mark as solved
-
i've had plenty of those days as well so I can relate.. glad I could help
-
you can use COUNT(DISTINCT) here $query = "SELECT engineer_id, COUNT(labour_id), COUNT(DISTINCT labour_id) FROM jobs_labour WHERE (date BETWEEN '2011-10-03' AND '2011-10-09') GROUP BY engineer_id"
-
what i gave you will keep you on the page for 5 seconds, then redirect using the meta tag to the specified URL
-
if you set a standard CSS style for a certain tag, to change an individual tag in that group, you wil either need to use the "style" attribute.. or another attribute like you used "color" to overwrite the group styling.. you can also set another class for the individual tag and use "!important" to override.. however in your case I do not recommend the latter of the suggestions..
-
not sure why you don't want to use a header here.. however to simply answer your question.. <meta HTTP-EQUIV="REFRESH" content="5; url=http://www.yourdomain.com/index.html">
-
then those two snippets will work for you
-
Regex Reading Web Page Problem (Not doing what i want)
AyKay47 replied to mikelmao's topic in Regex Help
here you go, i tested this.. I believe that your biggest issue was not including the s modifier and using ".", i believe that there are spaces and or newlines being used between the tags.. $roosterPage = "http://rst-vltn.roczeeland.nl/ovw/40/c/c00101.htm"; $rooster = file_get_contents($roosterPage); preg_match_all('~<font size="2" face="Arial">(.*)</font>~is', $rooster, $matches2); print_r($matches2); -
if you set an onsubmit javascript event handler on the form, and tell it to return false onsubmit.. this will ensure that if the user has js enabled.. the onsubmit event will handle it, however if they do not have js enabled.. PHP will handle it.. what the "return false" does is prohibits the default action of the form..(submit form via PHP, refresh page) and has the js function that you provide handle the form instead. <form onsubmit='somfunc();return false'> <input type='text' name='whatever' id='whatever'> <input type='submit' name='whatever1' id='whatever1' </form> some people like to set the onclick event on the submit button, however this is a common mistake, since the user also has the option of submitting the form by pressing enter..
-
1. if that string that you provided is going to be the same pattern every time... you can use this $string = "(123|789,1234)"; $pattern = "~\d{4}~"; preg_match($pattern,$string,$matches); foreach($matches as $match){ print $match."<br />"; } 2. you could combine regex with explode here.. $string = " _x[5,1,0,0,0,0,0,0,1,0,1,4,4,9,10,5]"; $pattern = "~.*\[([\d,]+)\]~"; preg_match($pattern,$string,$matches); $array_string = $matches[1]; $new_arr = explode(",",$array_string); print_r($new_arr);
-
Floating an image to the left and two paragraphs to the right
AyKay47 replied to music_fan01's topic in CSS Help
use margin-top or margin-bottom to separate your divs instead of breaks.. and the code that you wrote looks good in clearing the divs.. as long as that is your parent div that contains the floating divs.. clear:both is acceptable but in my opinion is an older practice.. And the margin-to/margin-bottom goes in the css correct? It turns out that I put my clear div in the wrong. I thought I had my floating divs in the main div, turns out I have them in the text div. answer to your question = yes -
what browser are you testing one? i believe that wmode=transparent will work on most browsers.. however it is not a universal fix
-
lol... i assumed the img tag was somewhere below the code he gave us..
-
php script does not show in a browser view source.. what directory is the page that you are calling these include from in, in relativity to the image directory..
-
i believe that you will want to add the flash var "wmode='transparent'" to your flash object.. this should integrate it into the html itself and allow you to layer things on top of it
-
the way that I pass PHP variables to javascript is via a javascript function somefunc("<?php echo $some_var; ?>")
-
what does a view source show your image paths as?
-
the only thing that i can think of here is that you want to use the link to call a javascript function? <a href='javascript:function()'> is this correct OP? an anchor tag is not necessary here, however it can be used.
-
yeah, really depends on the situation here and how many pages are to be created..