[PHP export] Custom stylesheets

Forum rules
Please consider the general rules for this board, before you enter the discussion.

Post a reply

Confirmation code
Enter the code exactly as it appears. All letters are case insensitive.
Smilies
:D :) ;) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :!: :?: :idea: :arrow: :| :mrgreen: :geek: :ugeek:
BBCode is ON
[img] is OFF
[flash] is OFF
[url] is ON
Smilies are ON
Topic review
   

Expand view Topic review: [PHP export] Custom stylesheets

Re: [PHP export] Custom stylesheets

Post by Eddy-R3 » Mon 15. Apr 2013, 11:06

Excellent thanks again Andreas! :) Worked out perfectly :D

Re: [PHP export] Custom stylesheets

Post by Andreas Rudolph » Sun 14. Apr 2013, 10:52

Hi Eddy-R3,

I've separated your question from the original thread into a separate thread.

Eddy-R3 wrote:ive tried adding custom style sheets to MyConfig.php and even tried setting the styles in style.php but that gets overwritten when you update the properties, how/where can i change the colours/styles of the details on the site? :)

You should not change "style.php" directly. These modifications get lost with the next export from ImmoTool.

If you want to override the default styles of "style.php", you should create a separate CSS file on your webspace - let's place it for example at http://emonestates.co.uk/immo/mystyle.css. Put all of your CSS modifications into this file. Maybe you should add an !important flag after each CSS rule in your "mystyle.css" file to make sure, that these definitions are processed with precedence (higher priority).

To make your "mystyle.css" known to the PHP export, you should place the following configuration into your "myconfig.php":

Code: Select all
  /**
   * Allgemeine Konfiguration überschreiben.
   * @param object $config Konfigurations-Objekt
   */
  function load_config_default( &$config ) {
    // Keinen Content-Type verwenden, wenn eine Einbindung durch einen Wrapper stattfindet
    if (defined('OPENESTATE_WRAPPER')) $config->ContentType = null;

    $config->AdditionalStylesheet = 'http://emonestates.co.uk/immo/mystyle.css';
  } 

The relevant part is "$config->AdditionalStylesheet = 'http://emonestates.co.uk/immo/mystyle.css';" - the rest should already be present in your "myconfig.php".

Please let me know, If you have a problem with a certain CSS modification. I think that most CSS issues, that occur together with the CSS of your CMSms template, can easily be fixed in the suggested way...

[PHP export] Custom stylesheets

Post by Eddy-R3 » Fri 12. Apr 2013, 18:40

Next question, lol sorry guys, styling, ive tried adding custom style sheets to MyConfig.php and even tried setting the styles in style.php but that gets overwritten when you update the properties, how/where can i change the colours/styles of the details on the site? :)

many thanks!

Top

cron