Giter VIP home page Giter VIP logo

Comments (10)

ellmetha avatar ellmetha commented on August 16, 2024

I believe this is related to a problem in the way your project is configured. Check your media configuration 😉

from django-precise-bbcode.

ellmetha avatar ellmetha commented on August 16, 2024

Closing since this is not really related to the project itself.

from django-precise-bbcode.

ViennaSand avatar ViennaSand commented on August 16, 2024

Dear ellmetha,
I wish you would be a bit more specific. I am undergoing the exact same problem and I have no clue what "check your media configuration" means. It would be helpful in your documentation to specify what we need to do in the install process not to undergo this problem.
Also, I wish I had more specific guidelines on how to have the buttons of the bbcode (just like here on github) in the admin area to enter the content of a blog post on top of the text area.
It may not be directly related to the project, but it is directly linked to the "getting started" doc.
Kind regards

from django-precise-bbcode.

jefpadfi avatar jefpadfi commented on August 16, 2024

The media settings are not part of the this project, which is what ellmetha was referring to. I forgot to set my media root and media url inside the settings.py. The following is what fixed my issue.

`# Media Root
MEDIA_ROOT = os.path.join(PROJECT_PATH, 'media')

MEDIA_URL = '/media/'`

Make sure you edit root to fit your project needs.

from django-precise-bbcode.

jefpadfi avatar jefpadfi commented on August 16, 2024

Also as far as the editor ellmetha mentions it will not be part of this project in another issue located here

#13

from django-precise-bbcode.

ViennaSand avatar ViennaSand commented on August 16, 2024

from django-precise-bbcode.

jefpadfi avatar jefpadfi commented on August 16, 2024

Again you cant just copy and past. My MEDIA_ROOT has PROJECT_PATH which is a custom variable i have created in my settings.py file. You will need to set up media_root to fit your project.

Also i would change smilies back to media as all uploaded content would end up int eh folder smilies then.

from django-precise-bbcode.

ViennaSand avatar ViennaSand commented on August 16, 2024

Thanks a lot with your hints, I could finally understand what I was missing:
once the MEDIA_ROOT and MEDIA_URL are setup in the settings.py

You have to go to urls.py and add the following:
from django.conf.urls.static import static
from my_project import settings (assuming that the MEDIA_ROOT is the my_porject folder)

and then url patterns =[
#whatever
] + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)

With this correction, when I upload the smiley in the admin page, I have access to my smiley, at last.
Now, I can focus on the rendering.

All the best!

from django-precise-bbcode.

jefpadfi avatar jefpadfi commented on August 16, 2024

Oh yea. I forgot about the urls.py file. Sorry about that.

from django-precise-bbcode.

ViennaSand avatar ViennaSand commented on August 16, 2024

No worries, it is also good to do part of the way in an autonomous way ;-) You've been so helpful! Thanks again

from django-precise-bbcode.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.