Re: Adding extension error
As I've said, you need a relationship to a image class.class MemberExtension extends DataExtension {   static $has_one = array(      'Avatar' => 'Image',   );   function updateCMSFields(FieldList...
View ArticleRe: Adding extension error
it was to no purposeI have Director::set_environment_type("dev"); in my _config.phpAfter login to CMS it jumps to Page section. If I press "Files" or eny else section, loader appears for a seccond and...
View ArticleRe: Adding extension error
I'm sure there is something in your error log. Did you rebuild your database? What version of Silverstripe do you use?Posted to: Adding extension error | Show Thread | Post Reply
View ArticleRe: Adding extension error
I use 3.0.55And yes, i did /dev/build and /dev/build?flush=all toomy log is empty or, rather, there are no today recordsPosted to: Adding extension error | Show Thread | Post Reply
View ArticleRe: Framework Only
No book is available yet for 3.0 (which would cover the new framework only functionality). Since it's a new feature it's still being improved but I've pushed a gist up of a basic app only bootstrap in...
View ArticleRe: How does Silverstripe work?
I have not been able to resolve is how to avoid the need to place code in my mysite Page class to retrieve dataCheckout DataExtensions. These can be applied to core objects to add functionality (such...
View ArticleRe: How does Silverstripe work?
Hi Willr,Thank you for your reply. Can I just confirm that I understand the implications of this? My understanding of classes is week so I may have got things wrong.Does this mean that if a template in...
View ArticleRe: How does Silverstripe work?
Does this mean that if a template in a published module contains a control structure, which for example retrieves data, the person installing that module will need to add code outside the module, such...
View ArticleRe: How does Silverstripe work?
Hi Willr,That is great.I am developing a site which uses 2.4 and I plan to examine sample code in the 2.4 book. I see that searching this code using the phrase "extends DataExtension" returned no...
View ArticleRe: Framework Only
As ever, cheers Will your a star, this gives me a starting point to have a play and see if i can make my sites framework only.Cheers again.Mick.Posted to: Framework Only | Show Thread | Post Reply
View ArticleUploadField path error
hi all.the error is that the uploadfield is saving the file in the rigth folder (temas), i check and the file is saved ok. but when in the template I link the file with $link or $URL the path is wrong,...
View Articledata object loop inside another loop not working
Hello,I have a page type "CentersPage" that shows centers in an accordion style. This page type has a "has_many" relationship with two data objects "Center" and "Location". Each accordion option has...
View ArticleRe: Silverstripe 3.0.2 - UploadField 400 Bad Request
Don't know if its related to your issue, but i found that the problem was my DataObject (an extension of SiteConfig) that I was adding the Image relation to, had not been saved initially. So after...
View ArticleRe: data object loop inside another loop not working
Hi Sajok,It looks like your page has many centers, buy your Center object only has one Location relationship. You can't loop a has one relationship.Try <div id="accordion"> <% if Centers %>...
View ArticleRe: UploadField path error
Hi again,I'm not 100% why this isn't working, but you could try $AbsoluteURL and make sure you ?flush=allAlso double check in the DB, making sure the correct path is saved in thereSELECT id,filename...
View ArticleRe: data object loop inside another loop not working
Hi Bambii7,I want the accordion options to be location names (ex: cities) not centers title. I want to loop through locations because each location has many centers that belong to it.Can you look at it...
View ArticleRe: data object loop inside another loop not working
Hi sajokYou can't loop your 'has many' as you haven't set it up - you need to add $has_many = array('Centers'=>'Center'); to your Location dataobject. That way, you won't have to manually set...
View ArticleRe: data object loop inside another loop not working
Thanks Kinglozzer, I added the missing has_many to Location dataobject, and it works now.Posted to: data object loop inside another loop not working | Show Thread | Post Reply
View ArticleRe: UploadField path error
hi again Bambii7 seems I'm the only with this problem :S.the $AbsoluteURL returns an incorrect path to the file too.I check the table File in the DB and the UploadField is saving the file with the...
View ArticleRe: UploadField path error
Umm lastly what are the permissions of the assets folder and an example uploaded image, it is possible they're able to write but unable to read the file.Posted to: UploadField path error | Show Thread...
View Article