Curtis Thompson
Forum Replies Created
-
hello…
i’d just use a file write type of thing like you have, but build it out in a variable first and then just write that once…but yes. there are a ton of ways to do what you want in php.
you could do it in a for loop over the post vars if you wanted to write them all, or you could add to that to filter out only fields that matched a certain pattern…but build the variable once and then write it all in one shot – that would be easier. i have a few functions that i put into an external lib that i use for any time i need it – here’s a write function from that lib:
/**
* writes the passed contents to the passed file
*
* $file: file (including path)
* $data: data
*/
function writeFileContents ($file, &$data) {// get rid of them ugly windows “^M” doohickies
$data = ereg_replace(“\r\n”, “\n”, $data);// write the file
$fp = fopen($file, “w”) or die (“unable to open $file for writing”);
fwrite($fp, $data);
fclose($fp);
}then it’s a quick call to write the variable that you’ve populated with your form data…i would probably skp creating the class in that instance – you can just loop through the $_POST array and get the data that way…
and with regards to the site messing up code – just put “<” instead of “<" and the html tags won't be parsed... sitruc
-
Curtis Thompson
December 18, 2005 at 11:06 pm in reply to: What books on PhP & MySQL will do the trick?hello…
hmm – it’s sort of a catch-22. a long-time php/mysql user would certainly be able to look at a book and tell you if it was good, but to be honest, i haven’t looked at a php or mysql book in a very long time… :-/
if you have any coding/db experience, both php and mysql are painfully easy to pick up. when i learned php, i knew perl (well, i still do i suppose) and php was a natural extension…it is also based a lot on c, so you would likely be able to pick it up right away just by diving in and trying stuff. there are a ton of examples online for doing just about anything you can imagine in php, and i bet if you took one of those and started playing around with it, you’d be up to speed in no time…
but back to books – i have generally always trusted o’reilly books, and they have one that they’ve kept up to date on the combo of php and mysql:
https://www.oreilly.com/catalog/0975240218/index.html
you might want to browse that one and see if it looks like it could be useful…but i still also recommend just poking around the net – php.net has the full api (as do a few other sites) and if you want to start with the basics, try google searches like “php guestbook” and the likes…
just my $.02… 🙂
sitruc
-
hello…
hmm. i see that here as well. it’s hard to say without having the code to poke around on (i mean i can view the source, but more that i don’t have the file all built here locally to play with)…all your numbers seem ok and as you noted, it works elsewhere. there are quirks in css positioning, though, and this might just be one of them…
what you could consider is a more traditional table layout – you can control padding, etc. and cell height (and maybe nested tables, as you’d need them for the 2nd vs. 3rd cols), but the nice thing is that your layout will stay aligned (which fixes this) but will also be more friendly for odd corner cases as well…
sitruc
-
hello…
well – root can see all, but if you mean admin in the sense of the os x admin account then you might need to get fancy with your groups underneath in unix.
if i were going to do this on a straight unix system, i’d do the following:
- create each user needed and make their home dir the desired folder
- create a group for each user and add that user to the respective group along with your admin user
- set the ownership for each respective user’s folder to 774 (unix group syntax – basically owner and group get full rights and everybody else can only read)
you can do all of this with the netinfo manager in applications -> utilities, but it does take some unix knowledge… :-/
outside of that, you could set each folder to be full-access only for the given user, but by default the os x admin won’t be able to see them then…
sitruc
-
hello…
[jeremy] ” Should it be done in flash?”
yup 🙂
you could do it with video, but straight video won’t get you the nice little load thingie – but if the bg of the video was the same color as the surrounding areas, you could put a video there…but that would be an immense pain, so flash would be the way to go…
sitruc
-
Curtis Thompson
December 12, 2005 at 9:36 pm in reply to: How do i display an image as a signature in my emailhello…
looks like the manual has you covered:
https://www.novell.com/coolsolutions/appnote/9961.html
which came from the last item here:
https://www.novell.com/coolsolutions/gwmag/ask_the_experts.html
sitruc
-
Curtis Thompson
December 12, 2005 at 4:57 pm in reply to: How do i display an image as a signature in my emailhello…
you could maybe use html and send all your messages as html, but that might be a bit risky as some people don’t use html mail readers…
but enough people probably do these days to maybe make it worth it if you really wanted to have a signature. you’d have to put your logo on a server somewhere and then reference it with an img tag in your sig…
hope that helps!
sitruc
-
hello…
check that you have windows sharing enabled in your sharing control panel…
sitruc
-
hello…
[robmaag] “You can
go to the site and email at by submitting the contact us link provided.”sorry – which part did you want feedback on?
sitruc
-
hello…
sorry – sorta missed the first mail there and only saw the videos. your code seems to be correct (both activex and embed), and i actually got these to play fine on my xp box with the 6.5.1 plugin (although i didn’t have audio on – but they started up fine and video was ok)…
it might be one of 2 things:
– a codec issue – activex and the pluginspage tag for embed will get you the plugin, but not the codecs that the movie was encoded with…so you have to use nice safe web-friendly codecs or else provide an additional link to the codec for install (if you can legally)
– limited version testing in the activex component…so not “what version do you have” but just “do you have a version”
the latter isn’t really fixable on your end unfortunately – an example from apple’s site for qt7 (unlreated but it has embed code) still uses the same activex control (which i’d expect) but they also refer to the same cab file you have:
so i’m not sure what to offer. typically with this sort of thing you might offer a v6 and v7 version or try to use javascript to analyze what version the user supports and give them the proper movie file automatically…
hope that helps a bit!
sitruc