SnippetMaster Support Forums
Return to main website
 
September 25, 2014, 12:06:19 AM
* Show unread posts since last visit.
* Show new replies to your posts.
Welcome, Guest. Please login or register.
Did you miss your activation email?
September 25, 2014, 12:06:19 AM

Login with username, password and session length
Search:  
Advanced search
* Home Help Search Login Register
SnippetMaster Support Forums  |  General  |  Pre-Sales Questions  |  Topic: CSS styles and classes in php include files « previous next »
Pages: [1] Print
Author Topic: CSS styles and classes in php include files  (Read 7125 times)
jakeferguson

Posts: 3


WWW
[-] CSS styles and classes in php include files
« on: December 08, 2009, 04:19:17 AM »

Hi

I am looking to purchase multiple licences of your great product - I have been playing a lot with the LITE version and have a few questions before I go ahead:

I have several php.inc files pointing to things like, header, footer and left column as these are common elements. However, i am having trouble connecting the CSS file to these. I can live with not having the text and backgrounds styled and just having text, but, the images I have need a class style placed in order for them to display properly. As there is no CSS being picked up this is causing problems for me. Is there a solution only available in the PRO version?

More questions:
Do I have to load the programme on every website I want to run it on or can I have a central one and define folders - whats the best practice?
I would like to buy the rebranded versions, do I have to then brand each one separately or do I rebrand one and then distribute as needed?

I look forward to your reply and am very impressed with this solution for my clients.

Jake
Report to moderator   Logged
admin
Forum Administrator
*
Posts: 3169

SnippetMaster Author


WWW
[-] Re: CSS styles and classes in php include files
« Reply #1 on: December 08, 2009, 04:27:00 AM »

Hi Jake,

Snippetmaster will automatically "find" any attached (linked) CSS files and inline CSS code and make it available in the editor.  Is that not working for you?

I'm also working on a new feature which will allow you to manually specify a CSS file to use when loading the editor. That should hopefully be ready within a few weeks.

>> Do I have to load the programme on every website I want to run

It really depends on how your websites are set up?  If all your sites are "under" a common folder, then you might be able to install SnippetMaster once and then create various users for each website. (Each user can have its own unique "starting folder" and "starting url".)  However.. snippetmaster was more or less designed to be installed seperately for each website it is meant to manage. 

>> do I have to then brand each one separately

Each installation of SnippetMaster is able to be branded seperately. For the rebrandable version, you just need to change the header/footer template files as desired.  If you have 10 different installations of Snippetmaster, then you would need to change the header/footer files for each of those installations.

You can find information about how to rebrand/customize Snippetmaster here:

http://www.snippetmaster.com/documentation/private-label-rebranding.html

Cheers!

Smile
Report to moderator   Logged
jakeferguson

Posts: 3


WWW
[-] Re: CSS styles and classes in php include files
« Reply #2 on: December 08, 2009, 04:34:12 AM »

Thank you for your amazingly prompt reply!

It is finding the CSS file of the whole documents absolutely fine - it is when I am loading a file that sits in the php.inc folder, eg, footer.inc.php If I look at the whole file for the index.php then the parts that are referred to as 'inc' files do not show up - which is fine. When I then navigate to the folder where all the inc files sit and load, the CSS is not being displayed. Also if I click the image and go to appearance the class style has nothing to display.

I have placed the snippet code around the contents of the inc file, also tried referring to it in the top of that document - nothing seems to work...

any ideas?

Jake
Report to moderator   Logged
admin
Forum Administrator
*
Posts: 3169

SnippetMaster Author


WWW
[-] Re: CSS styles and classes in php include files
« Reply #3 on: December 08, 2009, 07:07:18 AM »

If the CSS file is not referenced within the "include" file you are trying to edit.. then Snippetmaster has no way to know about it.  That's why it's not loading.

At the moment there is no solution for what you're trying to do (edit an "included" file and want the CSS in the "parent" file to be used).

I am working on a solution, which will allow you to manually specify a CSS file that will be opened with the editor, regardless of what file you're editing... this should be ready in a few weeks.

Report to moderator   Logged
jakeferguson

Posts: 3


WWW
[-] Re: CSS styles and classes in php include files
« Reply #4 on: December 08, 2009, 07:24:19 AM »

groovy - look forward to the update

 Very Happy
Report to moderator   Logged
eventide

Posts: 19


WWW
[-] Re: CSS styles and classes in php include files
« Reply #5 on: December 10, 2009, 09:19:51 AM »

I have a concern about php includes as well and it seems that this thread may address it, but I'm not positive.

First, I have not even loaded SnippetMaster, so I am not at all familiar with the program - I just stumbled upon this while searching for CMSs. However based on everything I've seen, I'm pretty sure I found my CMS solution for me and my clients!

I make heavy use of php includes to cut down on repeated coding from page to page. I generally have in a typical include file everything from the very top DOCTYPE declaration all the way down to the opening BODY tag and from the page footer down. In the included file are the doctype declaration, css reference path (I rarely use local, per-page styling), javascript, nav menu, etc, etc.

So, I saw this thread and immediately wondered if SnippetMaster will be able to properly work with how I have my files set up.

Thanks for any help!
Report to moderator   Logged

f u cn rd ths u cn gt a gd jb n prgrmmng
admin
Forum Administrator
*
Posts: 3169

SnippetMaster Author


WWW
[-] Re: CSS styles and classes in php include files
« Reply #6 on: December 10, 2009, 10:45:55 AM »

Hello,

OK.. here's basically what is the problem.

1. You have your "main" file called "index.php".

2. Inside the "index.php" file, you have an "included" file called "include.php".

3. If you load any HTML code from "index.php", then the Snippetmaster editor will have no idea about the included file which contains your CSS.

So the short answer to your question is that right now.. Snippetmaster is not able to "see" the CSS code you have specified in your included file.

I am working on a solution to this problem, which most likely will simply be a way for you to manually specify the location of the included file in the Snippet.. so that when the editor is loaded.. your CSS will be found.

I hope that makes sense?  Should be a week or so for it to be available. 

Smile
Report to moderator   Logged
eventide

Posts: 19


WWW
[-] Re: CSS styles and classes in php include files
« Reply #7 on: December 10, 2009, 11:38:45 AM »

Thanks a lot for the quick reply!

Your clarification makes sense. As it stands now, none of the pages I create would have any CSS that the SnippetMaster software could find, so I will certainly be looking forward to the update you promise!

Regards
Report to moderator   Logged

f u cn rd ths u cn gt a gd jb n prgrmmng
cedarcreek

Posts: 12


[-] Re: CSS styles and classes in php include files
« Reply #8 on: December 10, 2009, 05:59:23 PM »

Sorry for the pesky post in a different thread. This is exactly the thing I need, Henri!  Very Happy Very Happy Very Happy

Even specifying the location of the "global" CSS file that is dynamically included would suit 99% of my sites just fine!

Thanks for working on it.
Report to moderator   Logged
eventide

Posts: 19


WWW
[-] Re: CSS styles and classes in php include files
« Reply #9 on: December 11, 2009, 06:17:17 AM »

Even specifying the location of the "global" CSS file that is dynamically included would suit 99% of my sites just fine!

I second this. In most of my sites I've got one CSS file that all pages in the site use, but, as I said above, it's included n the page in a php include...

One question came to mind, will your fix work for any file included in the php include statement? (I'm thinking specifically of Javascript files...)
Report to moderator   Logged

f u cn rd ths u cn gt a gd jb n prgrmmng
deliwasista

Posts: 33


[-] Re: CSS styles and classes in php include files
« Reply #10 on: May 22, 2011, 04:11:17 PM »

How do we include the css in the snippet?
Report to moderator   Logged
Pages: [1] Print 
SnippetMaster Support Forums  |  General  |  Pre-Sales Questions  |  Topic: CSS styles and classes in php include files « previous next »
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!