-
Posts
364 -
Joined
-
Last visited
Never
Everything posted by the_oliver
-
CentOS does not offer much on its web site because it is exactly the same as RedHat Just free! The releces are made at almost identical times. Resion being some of the people who origionaly wrote the RedHat components when it was free did not want to pay for it. There for the only real diffrence is that theres no paid support. All of there rpms for redhat work on CentOS, and there is tones of help out there, as its the same as RedHat help. I would realy recomend CentOS 4.4 as its sercure, simple, and stable!! (plus yum is a really time saving feature!)
-
[SOLVED] PHP code from a database not run.
the_oliver replied to the_oliver's topic in PHP Coding Help
Been looking for that for week! Thanks. -
you could try simply printing the HTML resrech code. Will work anywere in the code. echo "<meta http-equiv=\"refresh\" content=\"0;URL=http://www.something.com/index.php?auth=fail\">";
-
Hello. I have a page which calls part of its contents from a database. This is normaly fine, however every now and again i need a bit of php code to be included in the contents pulled from the database. The only trouble is that because the php has already been procesed by the time it does the database queiry, it simply shows the code as clear txt. Is there a way round this? Thanks
-
I am using sessions. If i use session.gc_maxlifetime that would mean that i have to renew the sesion every, say 10mins, or whatever i set it to? I was thinking more along the lines of database and cron?
-
Hello, Im looking for a way to log a user out if they have been inactive for two long. My gues to for this would be to update a timestamp every time they do anything, and have a cron job log out any one who have a time stamp older then say 10 mins.... This is i have never used time stamps with a database etc before and have no idea how to compair them! Can anyone help? Many Thanks!
-
Hello I have two coloums, made by tables, into which i insert text. When i do this the second table (far right) the text feed into it only goes as far as the table width, and the downwords. However in the first table it goes over the table boundry and under the second table. How do i stop this???? Many Thanks! <TR><TD width="629" align="left" VALIGN=TOP> <TABLE width="643" BORDER=0 align="right" CELLPADDING=1 CELLSPACING=0 BGCOLOR=#486090> <TR> <TD width="629" ALIGN=CENTER><TABLE WIDTH=655 BORDER=0 align="left" CELLPADDING=4 CELLSPACING=0 BGCOLOR=#E0E8FF> <TR BGCOLOR=#000099> <TD width="371" ALIGN=CENTER valign="top"><font color="#FFFFFF"><strong> <?php echo $body_title; ?> </strong></font></TD> </TR> <TR> <TD><TABLE WIDTH=130% height="77" BORDER=0 align="left" CELLPADDING=10 CELLSPACING=0> <TR> <TD align="left" valign="top"><P> <?php echo $body_content; ?> </P></TD> </TR> </TABLE></TD> </TR> </TABLE></TD> </TR> </TABLE> <P></TD> <TD width="240" ALIGN=CENTER VALIGN=TOP> <DIV ID="DownloadHelp" STYLE="display:block"> <TABLE BORDER=0 align="right" CELLPADDING=1 CELLSPACING=0 BGCOLOR=#486090> <TR><TD ALIGN=CENTER> <TABLE WIDTH=238 BORDER=0 align="right" CELLPADDING=4 CELLSPACING=0 BGCOLOR=#E0E8FF> <TR BGCOLOR=#000099> <TD ALIGN=CENTER valign="top"><B><font color="#FFFFFF"> <?php echo $side_title; ?> </font></B></TD> </TR> <TR><TD> <TABLE WIDTH=100% height="82" BORDER=0 CELLPADDING=10 CELLSPACING=0> <TR><TD valign="top"> <FONT SIZE=-1> <P> <?php echo $side_content; ?> </P> </FONT><P> </P ></TD></TR></TABLE> </TD></TR> </TABLE> </TD></TR></TABLE> </DIV> </TD> </TR> (Strange thing is that in DreamWeaver it works as it should.)
-
Scrap that, got it! Many Thanks
-
Ok, so i use something like: while($query_data = pg_fetch_array($result)) {} Would is still need the for() statment or just put { echo $data["num"]; echo $spacer; } ?
-
Setting up PHP mail() function on new server
the_oliver replied to MortimerJazz's topic in PHP Installation and Configuration
You can specify a diffrent mail/smtp server to use in the php script, although i forget how to do it. All you need to do in the ini script make the standard mail() comand is enabled. (by default it is). As thorpe said though it is simpler just to set up a basic smtp server on the host. Is very important though to ensure that the local smtp server only allows localhost connections, else you may find your self blacklisted, (allowing to much spam relaying etc). -
good ideas. Thanks. But what about athenticating the user etc....
-
If you dont like Debian CentOS is always a good choice. As its so similer to redhat, its got loads of support, yum makes installing a doddle, and firewall is fantastic!
-
Very much doubt it. By the time the server gets to this stage it wil either run very slow, of just give no responce. As far as the server is concerned the only way to deal with .php files if to run them first. The only way it would show it straight would be if php was not installed! I doubt he can do what he says, as not all servers will have the same ports (eg ftp) open. + as DeathStar servers are quite secure now. If he has though he is minted!
-
Hello, Can someone tell me what im doing wrong hear? The first value is printed but then just the spacer. Eg. 937401 | | | | | | when it should be 2345 | 234523 | 23452345 | and so on. $query = "SELECT num FROM table WHERE id = '1'"; $result = pg_query($temp_pg_connection, $query); $data = pg_fetch_array($result); $entry_count = pg_num_rows($result); $spacer = " | "; if ($entry_count > 0) { for ($i=0; $i<$entry_count; $i++) { echo $data[$i]; echo $spacer; } } else { echo "no data apparently?"; } Many Thanks
-
sure, but i was wondering if there is a way to do it direct from postgres?
-
Hi, I realize this is a topic that people ask regualy, but i read a particular solution a while ago, but cant find it! I want to make a site as 'secure as possible'! At present i have a login comparing to a database, using md5 passwords. It is also connected to using SSL. The solution i saw i think involved a cookie changing every time a new page was requested, or something along those lines. Does this sound like a good solution, or is there a better? How would i go about doing this? Many Thanks.
-
Hello, I have a single six didget number srored in a table. Is there a way that i can make it automaticaly incriment by one ever day at midnight? Thanks!
-
SMTP is easly solved by requiring authentication. Also important to stop you from getting black listed. If your realy woried about it this to can be done over an SSL connection.
-
Virtual host not working from localhost?
the_oliver replied to edwinboersma's topic in Apache HTTP Server
Some routes have problems resolving address which point to them selves. Could this be it? -
If your server is set up well then your security will not be a problem! Linux is fairly 'bomb proof' as you put it, but only if you have it set up so! A good place to start would be the fire-wall. Try google for iptables. Also try restricting down you ssh logins in the sshd config. Complex root passwords also help. As to security of php scripts this realy depend how you write them. If you have them running under root, and storing important passwords on them then this can be a problem! If your scripts are running under Apache (most likly) then they can only do what apache can do. If you realy wish to restrict this you need to play around with the directory tags in the httpd.conf file. Dont forget that no one can reed your php scripts unless they can log into your server. The chance of a security problem from a php script is low. (if your talking about the security of members areas and things, this is a difrent isue, and you should ask in the php area.) Chances are the dark cloud is not neccecery!
-
Can you phrase that a little better. Apache does not need its own DNS server. Just an A-Record pointing to your hosting server. Could the DNS records not be hosted else where?
-
If your on dedicated this can be done as a virtual host in the apcahes httpd.conf file. It will however also need an A-record to be set up for x.y.com by your hosting company. If you can't change the httpd.conf file, then many hosting companys give you a 'domain forwording' option in your DNS controle pannal. Realy your best to see what you can get out of there support.
-
It can be 775 if the file is owned by the webserver group. Will also give a little more security on the files you put up there.
-
Perhaps you should also consider using an SSL connection.
-
Hi, Is there a way that i can make text (a link or something) do the same as submit button at the bottom of a form? Thanks!