Jump to:

5515 Posts in 1734 Topics by 1220 members

Customising the CMS

SilverStripe Forums » Customising the CMS » Color-picker?

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1 2 3 4 5
Go to End
Author Topic: 7776 Views
  • banal
    Avatar
    Community Member
    901 Posts

    Re: Color-picker? Link to this post

    1) The thing you downloaded is the JavaScript only. You also need the PHP class and some additional JavaScript to make it work in SilverStripe. Download it from my site: http://bummzack.ch/colorpicker (scroll down and download colorpicker.zip).

    2) dev/build is something quite fundamental when developing with SilverStripe. You have to do it whenever you add new modules or own page-classes to your website. Basically you just append /dev/build to the URL where SilverStripe is installed. So if SilverStripe is installed in http://localhost/silverstripe, it would be http://localhost/silverstripe/dev/build.
    I think you should really have a look at the SilverStripe tutorials.. it's all explained there: http://doc.silverstripe.org/doku.php?id=tutorials

  • Mikan
    Avatar
    Community Member
    17 Posts

    Re: Color-picker? Link to this post

    hi, banal

    Thanks for your replying. I am new to silverstripe ,

    I just downed the new "colorpicker.zip" from your site: http://bummzack.ch/colorpicker

    after unzip the colorpicker.zip file, I saw this folder has 2 folders, "__MACOSX" and "colorpicker" folder, I did to uploaded the ""colorpicker" folder to my silverstripe site Directory.

    and create a new ColorPage.php File, uploaded , then run dev/build by use: http://www.mysiteurl.com/dev/build)

    site auto forward to http://www.mysiteurl.com/Security/login

    my site still down, I don't know why .

    Please check my new "ColorPage.php" file below

    Thanks

    Attached Files
  • banal
    Avatar
    Community Member
    901 Posts

    Re: Color-picker? Link to this post

    /dev/build requires a login if your website is live.
    Either login, or if you can't do that due to the Error, add the following to mysite/_config.php

    Director::set_environment_type('dev');

    Then you should be able to run /dev/build without login.
    Your colorpage looks fine.

  • Mikan
    Avatar
    Community Member
    17 Posts

    Re: Color-picker? Link to this post

    yes, banal

    I just edited the file mysite/_config.php with code below:

    Director::set_environment_type('dev');

    after uploaded the file "_config.php" ,then run dev/build by use: http://www.mysiteurl.com/dev/build

    It take me to:

    Environment Builder (formerly db/build)
    ...
    ...
    Creating database tables
    ...
    Creating database records

    My site has been back to live, after I logined to my admin CP -site content,

    I can't see the "colorpicker" Module , I am not be able to edit color to my content.

    how to activation the "colorpicker" Module ?

    Thanks

  • banal
    Avatar
    Community Member
    901 Posts

    Re: Color-picker? Link to this post

    The colorpicker module just adds a new field to the SilverStripe form fields.
    If you create a new "Color Page" in the CMS you should be able to select a color on the color field you added there...

  • Mikan
    Avatar
    Community Member
    17 Posts

    Re: Color-picker? Link to this post

    hi,

    banal, I just created a page by choose" Color Page" , then click" Go"

    It take me to "Content creating"

    I can not see any color button and color words.

    thanks

  • banal
    Avatar
    Community Member
    901 Posts

    Re: Color-picker? Link to this post

    Do you see the text-field labeled "Background Color"? If you click on it, the color selector should appear.

  • Mikan
    Avatar
    Community Member
    17 Posts

    Re: Color-picker? Link to this post

    yes,

    I saw this "Background Color" ,

    Background Color,

    But to add the Color to my Content ?

    how to make the "Background Color" to Content?

    how to use the Color-picker ? how does it work on Content creating and text ?

    thanks

    7776 Views
Page: 1 2 3 4 5
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.