I have a model in django and I want to call the model's value fields in my style tag for a CSS property
but I face this error
Actually I want to set background-color from backend
how can I fix it?

at-rule or selector expected in django html
87 Views Asked by Shervin.bdn At
1
There are 1 best solutions below
Related Questions in HTML
- Delay in loading Html Page(WebView) from assets folder in real android device
- Why does a function show up as not defined
- CSS Class is not applying to element (border width,color,and style attributes)
- How to sort these using Javascript or Jquery Most effectively
- how to fill out the table with next values in array with one button
- Automatically closing tags in form input?
- Positioning child at bottom of parent with scroll
- Remove added set of rows
- Website zoomed out on Android default browser
- Twitter Bootstrap horizontal form elements on a line
- http://sigmajs.org/ les mis tutorial - why are my canvases 0 height?
- My navbar is not expanding after collapse
- when a checkbox is checked how to display a different hidden element using javascript
- Gaps Vertically Using Dividers
- Svg containers not positioning properly
Related Questions in CSS
- CSS Class is not applying to element (border width,color,and style attributes)
- How do I find the fonts that are not loading in a CORS situation ( MoovWeb )?
- Positioning child at bottom of parent with scroll
- Play multiple audio files in a slider
- How to set text over image?
- Website zoomed out on Android default browser
- Writing/Overwriting to specific XML file from ASP.NET code behind
- My navbar is not expanding after collapse
- when a checkbox is checked how to display a different hidden element using javascript
- Gaps Vertically Using Dividers
- CSS: Preventing a property to affect on element until the end of transition
- Polygon Button with pure CSS
- transform-origin doesnt apply in safari
- show/hide multiple div tags at once and change the size of the remaining div tag
- Mask the image/maps/div (circle) using css and jquery
Related Questions in DJANGO-MODELS
- Django invalid literal for int() with base 10:
- How to translate this raw query to Django ORM
- How to add methods to customised search_fields in Django admin.ModelAdmin
- Django - how replace values in a model nested in a list of lists
- How to retrieve an object or a particular field from context object in view?
- How to make a single form for two related models?
- How to create object from QueryDict in django?
- Permission denied on trying to write file
- How to reverse query objects for multiple levels in django?
- Get element of table by instance of foreign key.
- Modify db object field from .py file in django
- How to filter objects for count annotation in Django?
- How to count users in JOINed models?
- "DatabaseError: duplicate column name" - bug with custom model's abstract class in django test
- Django models: managing transactions when commit_manually is deprecated
Related Questions in DJANGO-TEMPLATES
- How to translate this raw query to Django ORM
- How to retrieve an object or a particular field from context object in view?
- Display a specific template when Django raises an exception
- How to manage media files on Windows?
- How can i check if values of models are the same in django loop?
- get rows count from django_tables2
- Serving static files in django 1.8
- Using Django FormPreview the right way
- Is it possible to display a specific block from a template in django?
- How do I display a related object set in django?
- How to loop over datetime range in django templates
- How should I show results of BeautifulSoup parsing in Django?
- Create table with id dynamically by template in Django
- In Django template how to separate Date and time from DateTimeField?
- django-bootstrap3 fields width control
Related Questions in DJANGO-CONTEXT
- Is there a list of default template variables in django?
- Django simple_tag and setting context variables
- Django {{site}} template context not working?
- How to use sekizai's addtoblock tag inside a form widget template
- Setting initial formfield value from context data in Django class based view
- What is a context in Django?
- django update view and passing context
- django url parameters into context_processor
- at-rule or selector expected in django html
- How do I inherit from different templates in Djanog based on whether the user is logged in or not
- Django context processor made available without a view
- Accessing global variable in view using context processor in Django
- User Context in Django
- Django last visited urls list
- Read request variable in template tag
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
This is not an error, this is just Visual Studio that does not understand that the template is being rendered.
Indeed, the template inspector expects something like:
now given that the
settings.website_background_colorexists, and is valid, it will render that, but the Visual Studio inspector does not know you will render the template.There might however be a problem that Django will ampersand-escape content. You can avoid that with the
|safetemplate filter [Django-doc], but this will not remove the warning: