On Sunday, March 9, 2014 12:11:11 PM UTC-4:30, rafiee.nima wrote:
>
> I am new to bootstarp and I want to use it in my django project.
> I put the needed folder's(css , js , img) in my project static folder and 
> config my setting.py to access static directory
> I can access bootstrap.css from http:///..myprojecet/static/bootstrap.css 
> which means I correctly config setting.py
> but the problem is that no bootstrap style applied to my temeplates. (I 
> also check in  firebug if css and js files been inclueded )
>
> here is my base.html code that other templates inhierent from it
>
> {% load static %}
> <!DOCTYPE html>
> <html>
> <head>
>     <meta name="viewport" content="width=device-width, initial-scale=1.0">
>     <!-- Bootstrap -->
>  <link href="{% static 'css/bootstrap.min.css'% }" rel="stylesheet" 
> media="screen">
> <link href="{% static 'css/bootstrap-theme.min.css' %}" rel="stylesheet">
>  </head>
> <body>
> <div class="btn-group dropup">
>   <button type="button" class="btn btn-default">Dropup</button>
>   <button type="button" class="btn btn-default dropdown-toggle" 
> data-toggle="dropdown">
>     <span class="caret"></span>
>     <span class="sr-only">Toggle Dropdown</span>
>   </button>
>   <ul class="dropdown-menu">
>   </ul>
> </div>
> {% block body_block %}
> {% endblock %}
>
> <script src="{% static 'js/jquery-2.1.0.js"></script>
> <script src="{% static 'js/bootstrap.min.js"></script>
> </body>
> </html>
>
Hello,

This URL looks bad:  http:///..myprojecet/static/bootstrap.css
What is in your settings.py?
Should it be: {% static 'bootstrap.min.css'% }?

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/7c7fb06b-67f2-4a8a-b3f8-cc11ef0cedfe%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to