|
Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon. |
|
View previous topic :: View next topic |
Author |
Message |
GELight Smarty n00b
Joined: 08 Mar 2012 Posts: 4
|
Posted: Thu Mar 08, 2012 3:04 pm Post subject: Pfad zu meinen CSS Files |
|
|
Hallo ale zusammen,
Dachte mir es kann nicht schaden sich doch mal hier anzumelden.
Ich habe eine kleine Verständnisfrage zu den Pfaden in Smarty.
meine Templates liegen im Verzeichnis "...../templates/".
Meine CSS Files habe ich in einem Verzeichnis "static/css/reset.css".
Meien Frage ist nun, wo ich das static-Verzeichnis hinpacken muss, damit Smarty alles findet?
Ich muss noch dazu sagen, dass ich die URL per htaccess rewrite und die URLs zB so aussehen:
http://beispiel.de/admin/Info
oder
http://beispiel.de/Login
Gruß Mario |
|
Back to top |
|
Grizzly Smarty Pro
Joined: 15 Apr 2011 Posts: 172 Location: Germany
|
Posted: Tue Apr 03, 2012 12:22 pm Post subject: |
|
|
Hä? Wenn du CSS verwendest, kannst du es doch referenzieren wie du lustig bist. Das hat doch mit Smarty nichts mehr zu tun und es würde weiterhin funken!
Referenzieren tust du einfach von der aktuellen php Datei. Beispiel:
- smarty
---Smarty.class.php
---plugins
---......
-templates
---index.tpl
---header.tpl
---footer.tpl
---......
-pages
---index.php
---contact.php
---.....
-static
---css
------reset.css
------..........
bist du also in meineHP.de/index.php referenzierst du zu "../static/css/reset.css" |
|
Back to top |
|
TomTo Smarty Rookie
Joined: 30 May 2009 Posts: 18
|
Posted: Wed Apr 04, 2012 2:09 pm Post subject: |
|
|
Wie schon gesagt, Smarty ist es eigentlich egal Wo Deine CSS Files liegen, oder ob Du überhaupt welche verwendest.
Ich für meinen Teil, binde sie am liebsten in dem Header Template ein.
Das ist auch sinnvoll so, gerade wenn man noch verschiedene Styles hat.
Code: |
<link rel="stylesheet" type="text/css" href="css/style.css" media="all" />
|
|
|
Back to top |
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|