Answer the question
In order to leave comments, you need to log in
How to make a button for loading images in the additional field DLE when you click the review?
I rummaged through the whole Google (I found only 1 way and that is not working.
It is necessary to implement the selection of an image from the computer and uploading it to the server after inserting a link to the image in the additional field, when adding news, I am attaching a screenshot of my form for adding news, alas, the horseradish button understand how to configure (
Answer the question
In order to leave comments, you need to log in
The two options are either to write your own crazy comparator that treats zero in a special way, and then do a std::sort.
Or sort as usual, and then move the zeros to the beginning.
It's very simple - qsort or std::sort have a compare procedure call as a parameter.
Here in this procedure, before comparing, bring the compared values to unsigned (unsigned), and only then compare. Then -1 will become 0xffff and will be > 0.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question