FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » Using a single php entry file for a whole site.
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: Using a single php entry file for a whole site. [message #181884 is a reply to message #181877] Thu, 20 June 2013 23:37 Go to previous messageGo to previous message
Jerry Stuckle is currently offline  Jerry Stuckle
Messages: 2598
Registered: September 2010
Karma:
Senior Member
On 6/20/2013 6:34 PM, Christoph Michael Becker wrote:
> Am 20.06.2013 23:38, schrieb The Natural Philosopher:
>> I think the general ideas of how to do it is now pretty clear, but there
>> are some detail issues as to how much can and should go IN the database.
>>
>> I think anything small can, but big images and videos? Hmm.
>
> Why do you want to put images and video files in the database?
>

Nothing wrong with it. Amongst other things, it makes things easier to
back up. You can also better sure integrity of your site because it's
impossible to delete an image in use if your foreign keys are set up
properly.

>> Can you execute PHP code stored in a database??
>>
>> I suppose in the limit you could write it to a file, and once written
>> include() it?
>>
>> is there a better way? eval()? It comes with health warnings..
>>
>> ..select page from code_table where id='12345'..eval (page)...hmm.
>
> Writing PHP code stored into a database to a file and including it is
> not safer than eval()ing it in the first place, IMO.
>

I agree here. Neither is safe, but necessary if you're writing a CMS.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex(at)attglobal(dot)net
==================
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Updating old PHP code
Next Topic: Komodo Edit
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Fri Nov 22 07:26:05 GMT 2024

Total time taken to generate the page: 0.04192 seconds