Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We're retiring the forums!

The SilverStripe forums have passed their heyday. They'll stick around, but will be read only. We'd encourage you to get involved in the community via the following channels instead:

Go to End

3 Posts   1710 Views


Community Member, 4 Posts

10 May 2010 at 10:32am

Hey there,
New to silverstripe and trying to import a file with fopen.
Is there a reason why I can't get this to work in silverstripe?


Forum Moderator, 5523 Posts

10 May 2010 at 10:35pm

Hi Jamie Welcome to the Forums.

Do you get an error message when trying to use fopen? It is likely that may have got the path to the file to import open. The base path for SilverStripe is in sapphire/main.php so if you want to get into the mysite folder then you have to either go up a folder (../mysite) or use an absolute url would work.

Other reason could be that its a permissions issue trying to read it.


Community Member, 254 Posts

31 August 2010 at 11:32pm

ahhh thanks again Willr,
I forgot SS sets the base path!