Which one is prefered? I have huge problems getting 4.1 to work. 4.0 finaly works again. Should I continue struggling to get 4.1 up and working (using debian) or could I settle with 4.0? Im running a quite large/busy site with it...
102 2005-01-21 01:08
Re: search string process so it's safe to use with database (php/mysql) (7 replies, posted in Programming)
Nevermind, I think I understand how it works now. Did not even need the mysql_escape_string(), it was escaped anyway on insert.
Thanks for you help...
103 2005-01-21 00:21
Re: search string process so it's safe to use with database (php/mysql) (7 replies, posted in Programming)
Thats wierd. I use mysql_escape_string($string);
insert it in the database (say it looks something like \"\" in the database)
then I get it in php, and it still is \"\", only if I use stripslashes it becomes "" like I want it.
I have set_magic_quotes_runtime(0);
I've read a little about it (apparently not enough :) and from what I understanit should be unescaped automaticly? what am I missing here?
104 2005-01-20 14:55
Re: search string process so it's safe to use with database (php/mysql) (7 replies, posted in Programming)
Another question in the same area.
After inserting a row in mysql (and after had run mysql_escape_string..)
To fetch that string and display it safely (like in a text-form i.e.)
is this the "right" way to do it.
$row = mysql_fetch_assoc(....
$row[search_string] = htmlspecialchars(stripslashes($row[search_string)); ?
I dont want anything to be messed up if user typed any kind of quotation mark.
105 2005-01-20 13:46
Re: search string process so it's safe to use with database (php/mysql) (7 replies, posted in Programming)
thats it?
i've used other function before but this one sounds more simple
thanks anyway.
106 2005-01-20 11:07
Topic: search string process so it's safe to use with database (php/mysql) (7 replies, posted in Programming)
If i've got something like this:
// a search string from URL
$search_string $_GET['search'];
//
// Some processing of the string here...
//
// a possible query with full text search
$query = "SELECT * FROM table WHERE MATCH (content) AGAINST ('$search_string')";
// another possible query
// $query = "INSERT INTO table (asdf) VALUES ('$search_string')";
mysql_query($query);
How is the best way to proccess that string so it's not posible to do something harmful in the database. Like SQL-injections, or similar...
107 2005-01-14 19:01
Re: Apache2 question (4 replies, posted in General discussion)
Connorhd: i've tried that allready '
Dosent work at all. Apache seems to just drop everything of that request if LimitRequestBody condition is confirmed.
108 2005-01-14 18:42
Re: Apache2 question (4 replies, posted in General discussion)
Do you have any other suggestion then? I dont want the file to be uploaded first and then perform a size check. If that is possible in anyway else than with LimitRequestBody
109 2005-01-14 18:26
Topic: Apache2 question (4 replies, posted in General discussion)
Hi. I want to use LimitRequestBody 1048576 in a .htaccess, if an uploaded file is larger than that, I want the user to be redirected to /asdf.html or something. Is this possible? I have searched on google alot and I haven't found anything of use yet.
110 2005-01-11 09:51
Re: 1.3? (43 replies, posted in PunBB 1.2 discussion)
Presonally I think PM is allmost necessary in a forum today. At least there could be an option to enable or disable the PM-function. Polls is not that important I think, but it's a nice feature.
I think you could use (with permission of course) the modules Chacmool wrote för 1.1.5, or at least consider creating something compatible to those (at least the PM-module) ...
111 2005-01-10 16:24
Re: Private Message System (332 replies, posted in PunBB 1.2 modifications, plugins and integrations)
Come on, where is the PM-module for 1.2?
112 2005-01-10 08:30
Re: PM-module and Poll-module for 1.2? (2 replies, posted in Feature requests)
ah, my mistake
113 2005-01-10 08:11
Topic: PM-module and Poll-module for 1.2? (2 replies, posted in Feature requests)
When will the PM-module and poll-module be converted to 1.2? If ever that is...
I look forward to it anyway. I wont be able to upgrade my forum unless there is a compatible PM-module (with 1.1.5) on 1.2, so start working Chacmool
Rickard: 1.2 Looks great btw, congrats!
/C
Edit: changed "Connorhd" to "Chacmool"
114 2004-12-20 01:47
Re: PunBB is too simple (21 replies, posted in General discussion)
PunBB is too simple!we need more!
To simple for what?
115 2004-12-11 19:06
Re: Free PHP/HTML editor (99 replies, posted in Programming)
I use Crimson Editior
Very nice with php/mysql and such. Freeware also.
oh, Jop already suggested it. oh well
116 2004-12-11 19:02
Topic: (advanced?) cutting of subject names to fit a certain table width (1 replies, posted in Programming)
Is there a way to cut a subject string to fit a certain table width?
I use Verdana alt Arial as fonts.
I want this:
"A long subject that will be cut becouse its to long to fit"
=> "A long subject that wi ..."
That is no big deal to do, BUT I think this is:
Since this forum uses Verdana also you notice the diffrence in these chars (both rows have 10 chars each):
aaaaaaaaaa
mmmmmmmmmm
This means I cant set a max width that fills the whole available table width i have (about 160px) and still avoid the table being streched if someone creates a thread containing "mmmmmmmmmmmmmmm" for example.
This is how it could look like if I cut after 17 chars. The table width is OK, but only the "mmmmmmm..." uses the entire space available:
Is there some way to fix this?
117 2004-12-01 02:43
Re: Php question (6 replies, posted in Programming)
I try to understand your question, but I can't .. You could either wait and hope someone else understand or you could try to explain better what you want
118 2004-11-30 17:54
Re: PunBB 1.2 Beta (254 replies, posted in PunBB 1.2 discussion)
oh. Nice scrollbar. In my current version (1.1.1) the whole forum gets expanded by the image.
Just forget what I said then
119 2004-11-30 17:41
Re: PunBB 1.2 Beta (254 replies, posted in PunBB 1.2 discussion)
chrizz wrote:2004-11-24
""""""""""
* Replaced the new admin option "Image max width" with "Image max height".
Instead of limiting the maximum width of images, which is taken care of by
scrollbars anyway, the new setting limits the height of images.Rickard: This is actually a problem for those (Im one of them) who implemented the forum in a existing site structure with constant width. In 1.1.1 I had to edit the forum myself. Now since I see you've implemented a function for this I actually dont see why there should not be an option to set max width AND height, or just one of them.
/C
But if an image is too wide, it will get scrollbars anyway, so I can't really see what the problem is.
Are we talking about the same images? Im not talking about avatars, but the [img]url_to_image[/img].
The page gets scrollbars, yes, but I dont want them. Thats the problem ... I want the image to fit in something like 500x500.
edit: and then a link to the fullsize-version
120 2004-11-30 17:18
Re: PunBB 1.2 Beta (254 replies, posted in PunBB 1.2 discussion)
2004-11-24
""""""""""
* Replaced the new admin option "Image max width" with "Image max height".
Instead of limiting the maximum width of images, which is taken care of by
scrollbars anyway, the new setting limits the height of images.
Rickard: This is actually a problem for those (Im one of them) who implemented the forum in a existing site structure with constant width. In 1.1.1 I had to edit the forum myself. Now since I see you've implemented a function for this I actually dont see why there should not be an option to set max width AND height, or just one of them.
/C
122 2004-11-24 21:44
Topic: Another mysql-question (2 replies, posted in Programming)
Hi!
I have this query:
SELECT a.*, i.filename AS first_image FROM ads AS a INNER JOIN ads_images AS i ON i.adid = a.adid WHERE ... GROUP BY adid ORDER BY a.timestamp DESC, i.filename ASC LIMIT 10;
As you can se there are two tables. An ad could have one image (or more than one) or no image at all. The ads_images contains only images, and no null-value-rows for the ads who dont have images (rows with the adid and null for the rest of the columns that is).
The query above results only rows containing ads with images, the ones without are not selected since there is no adid in ads_images for that ad. Is there another solution to this than to insert "null-rows" to the ads_images but only containing the adid?
123 2004-11-20 17:29
Re: FAQ: Copyright (68 replies, posted in PunBB 1.2 discussion)
A couple of years ago I would have probably removed the copyright notice. Lately i've been programming alot my self and I know how much time goes into something like this. I would be mad if someone basicly took credit for my work so I would never do it to anyone else. Give the guy some credit, keep the copyright and link. Thats not much to ask, is it?
124 2004-10-31 13:04
Re: The redirection message... (13 replies, posted in Feature requests)
Rickar: Ok, great
125 2004-10-31 02:06
Re: Banned users remain online (6 replies, posted in PunBB 1.2 bug reports)
When I think of it Smartys explanation makes sense...