icon Get the most out of Surmunity, read our tips here! Need an interesting blog to read? You've got to read the Surpass Blog! | Welcome! Please register to access all of our features.

» Surpass Web Hosting Forums » Discussions » PHP, MySQL » php includes on different account

PHP, MySQL General PHP questions. Or go to our PHPsuexec Forum >>

Reply
 
LinkBack Thread Tools Search this Thread Rate Thread
Old March 22nd, 2008, 10:40 AM   #1 (permalink)
mgk
Registered User
Excelling Contributor
 
Joined in Mar 2007
Lives in Wales
Hosted on dime999
620 posts
Gave thanks: 47
Thanked 46 times
php includes on different account

On my previous hosting I was able to include files (PHP) from a special account which meant that for all my customers I could centrally update my scripts.

Security seems to not allow that here - is there a workaround?
__________________
Markus
mgk is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old March 22nd, 2008, 10:50 AM   #2 (permalink)
Surpass Fan
Excelling Contributor
 
cowboy's Avatar
 
Joined in Nov 2005
Lives in Colorado
Hosted on DEDI
936 posts
Gave thanks: 2
Thanked 95 times
Quote:
Originally Posted by mgk View Post
On my previous hosting I was able to include files (PHP) from a special account which meant that for all my customers I could centrally update my scripts.

Security seems to not allow that here - is there a workaround?
No. This is a feature of phpSUexec. (SU = set user). Only the owner can execute a php file.

You will need to copy and place them within your user space.
__________________
Where would you be if you were at the highest court in the land (US)?
cowboy is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old March 22nd, 2008, 11:28 AM   #3 (permalink)
Surpass Fan
Excelling Contributor
 
cowboy's Avatar
 
Joined in Nov 2005
Lives in Colorado
Hosted on DEDI
936 posts
Gave thanks: 2
Thanked 95 times
I think there is a way. You will have to try.

1. Make a script for a cron to run that will write the includes to a database.

2. Give each domain access to that database.
__________________
Where would you be if you were at the highest court in the land (US)?
cowboy is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old March 24th, 2008, 5:14 AM   #4 (permalink)
Registered User
Comfy Contributor
 
nathon's Avatar
 
Joined in Sep 2007
Lives in ~root
111 posts
Gave thanks: 1
Thanked 12 times
you are pretty much stuck on this one.

It is just the nature of phpsuexec to prevent this. In actuality it is a great thing to have on shared servers because you don't want someone else executing/modifying your files or even worse is having them upload a c99 shell.
__________________
I'm proud to say I never have and never will use vista
nathon is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old March 26th, 2008, 11:35 AM   #5 (permalink)
Senior Member
Super #1
 
FredFredrickson's Avatar
 
Joined in Nov 2003
Lives in New Hampshire
1,260 posts
Gave thanks: 3
Thanked 27 times
Depends on how much information you'll need passed from the script. You can do an include to an external URL, but it won't pass variables and such.
Code:
include("http://www.yahoo.com");
__________________
FredFredrickson is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old March 26th, 2008, 1:08 PM   #6 (permalink)
Surpass Developer
Excelling Contributor
 
Mark's Avatar
 
Joined in Jan 2004
Lives in Florida
Hosted on decc.surpasshosting.com
511 posts
Gave thanks: 20
Thanked 78 times
Quote:
Originally Posted by FredFredrickson View Post
Depends on how much information you'll need passed from the script. You can do an include to an external URL, but it won't pass variables and such.
Code:
include("http://www.yahoo.com");
This won't work on most of our shared servers as allow_url_fopen is most likely turned off. You could turn it on via php.ini if you are on a suexec server, however that is not a smart idea unless you don't have any variables in include/require statements in any of your code.
__________________
Mark
Surpass Hosting Developer
sɹnoʎ uɐɥʇ ɹǝʇʇǝq sı bıs ʎɯ
Mark is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old March 26th, 2008, 1:24 PM   #7 (permalink)
Senior Member
Super #1
 
FredFredrickson's Avatar
 
Joined in Nov 2003
Lives in New Hampshire
1,260 posts
Gave thanks: 3
Thanked 27 times
or you could fopen() and read in the page. What's the application for this?
__________________
FredFredrickson is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old March 26th, 2008, 1:37 PM   #8 (permalink)
mgk
Registered User
Excelling Contributor
 
Joined in Mar 2007
Lives in Wales
Hosted on dime999
620 posts
Gave thanks: 47
Thanked 46 times
The application would be to have a shared library of modules available across a number of accounts.
__________________
Markus
mgk is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old March 26th, 2008, 3:51 PM   #9 (permalink)
Senior Member
Super #1
 
FredFredrickson's Avatar
 
Joined in Nov 2003
Lives in New Hampshire
1,260 posts
Gave thanks: 3
Thanked 27 times
yeah, your best bet is distributing copies of the file to every account.
__________________
FredFredrickson is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On