Search found 22 matches

by gregor171
Tue Jul 14, 2009 4:45 pm
Forum: PHP - Theory and Design
Topic: Enhanced objects and reflection
Replies: 8
Views: 1263

Re: Enhanced objects and reflection

Improved in what way. You might be thinking of something more easy to use? A wrapper class?

ps: Reflection is already OO.
by gregor171
Tue Jul 14, 2009 4:38 pm
Forum: PHP - Theory and Design
Topic: PHP File Contents Screenshot
Replies: 2
Views: 741

Re: PHP File Contents Screenshot

Interesting issue with no desktop on the server ;-)
by gregor171
Wed May 20, 2009 11:19 am
Forum: Installation and Configuration
Topic: Page displaying cade rather than end result
Replies: 2
Views: 1035

Re: Page displaying cade rather than end result

OS?

In debian you have dir modules-available and link in model-enabled for enabling them.
by gregor171
Wed May 20, 2009 11:16 am
Forum: HTML, CSS and other UI Design Technologies
Topic: FireFox <td> height
Replies: 4
Views: 2874

Re: FireFox <td> height

I'd say that this is problem of code viewer. Sometimes you don't see what you send. Change or try other page preview plugin.

else:
small letters are more common now w3c way: http://www.w3.org/TR/xhtml1/.

<td> is now offten replaced with <div> element
;-)
by gregor171
Wed May 20, 2009 11:09 am
Forum: PHP - Code
Topic: Need meaning of an if statement.
Replies: 1
Views: 165

Re: Need meaning of an if statement.

Looks like a part of navigator code. I believe that there should be a line that sets $submenu somewhere up the code or in else sentence that follows if. The other possibility is that a submenu haven't been implemented. $cat in the other hand has integer value (what isn't best SEO practice) and match...
by gregor171
Tue Apr 21, 2009 2:32 pm
Forum: PHP - Code
Topic: PHP parse error using mysql functions in and if statement :S
Replies: 4
Views: 377

Re: PHP parse error using mysql functions in and if statement :S

Looks like error in line 22.         if ($sql)[color=#FF0000]{[/color]              mysql_select_db($db_name,mysql_connect("$db_host", "$db_user", "$db_password"));              mysql_query($sql,mysql_connect("$db_host", "$db_user", "$db_passwor...
by gregor171
Tue Apr 21, 2009 2:11 pm
Forum: PHP - Security
Topic: 301 permanent redirection except secure domain
Replies: 3
Views: 997

Re: 301 permanent redirection except secure domain

you can simply redirect it by checking where request came from
$_SERVER['SERVER_NAME']

to see if it's https:
$_SERVER['HTTPS']

and redirect it with header() function.
by gregor171
Tue Apr 21, 2009 1:55 pm
Forum: PHP - Security
Topic: Yep, Another login script
Replies: 38
Views: 10245

Re: Yep, Another login script

It might help to do some base reading:
http://phpsec.org/library/
http://cwe.mitre.org/top25/
by gregor171
Tue Apr 21, 2009 1:32 pm
Forum: PHP - Security
Topic: $_SESSION security
Replies: 4
Views: 1063

Re: $_SESSION security

You can't actually trust anything that you get from request. There are many ways to upgrade your session security: http://shiflett.org/articles/the-truth-about-sessions I mix different techniques and also store more than just session id in $_SESSION. I store an object that holds more informations ab...
by gregor171
Tue Apr 21, 2009 1:15 pm
Forum: PHP - Security
Topic: PHP Code security
Replies: 2
Views: 815

Re: PHP Code security

I suggest start reading, it's better to know than asking around:
http://phpsec.org/
http://cwe.mitre.org/top25/
by gregor171
Tue Apr 21, 2009 1:12 pm
Forum: PHP - Code
Topic: Designing my own CMS
Replies: 1
Views: 364

Re: Designing my own CMS


1. include 'themeheader.php';
2. echo $content;
3. include 'themefooter.php';
jp. those were the days.
here is a simple solution http://www.planet-source-code.com/vb/sc ... 3&lngWId=8
by gregor171
Tue Apr 21, 2009 1:09 pm
Forum: PHP - Security
Topic: best security for an url
Replies: 8
Views: 1502

Re: best security for an url

I liked the key idea.
I was wondering, wouldn't it be better to POST this content instead of GET?
by gregor171
Tue Apr 21, 2009 12:06 pm
Forum: PHP - Theory and Design
Topic: Large scale website - which concept/design to use?
Replies: 25
Views: 5445

Re: Large scale website - which concept/design to use?

ps: for heavy traffic site have in mind that mySql official supports covers up to 5.000 q/sec. but I've seen that it can handle 50k q/s.
Heavy traffic is what we all want ;-)
by gregor171
Tue Apr 21, 2009 12:03 pm
Forum: PHP - Theory and Design
Topic: Large scale website - which concept/design to use?
Replies: 25
Views: 5445

Re: Large scale website - which concept/design to use?

Ok I'm a Newbie but I worked in heavy load environment. First u have to determine what is a heavy traffic for you and what are your resources (how many servers). 1. Using database is nice and simple, but can be costly. as said connections take time even if your query's are cached 2. We used file cac...
by gregor171
Tue Apr 21, 2009 11:16 am
Forum: PHP - Theory and Design
Topic: Methodology for domain development
Replies: 4
Views: 939

Re: Methodology for domain development

I use cards and process draw. Full wall of them. In the process I try to isolate "black boxes" with unique functions and the one with settings or related but related content (as article and article_comment). I found a great source of ideas, how to get trough architecture by using patterns....