Advertisement:

Author Topic: [Plugin] Front-end Admin Edit v0.21  (Read 5271 times)

Gilden

  • Sr. Member
  • ****
  • Posts: 464
  • Availability: 30%
[Plugin] Front-end Admin Edit v0.21
« on: June 17, 2013, 11:17:12 pm »
This is a very simple plugin.
It shows a big red button on the listing page that will take admins directly to the edit listing page.
It's something I've been using for a while, and I thought of sharing it since it may be useful to some people.

Just upload the plugin, install, and make sure you have an account on your site with the same email address as your administrator address.
« Last Edit: September 06, 2013, 03:56:35 am by Gilden »

SlicK

  • Newbie
  • *
  • Posts: 30
Re: [Plugin] Front-end Admin Edit
« Reply #1 on: June 18, 2013, 05:15:29 am »
Very nice! I love these kinds of ideas.

Gilden

  • Sr. Member
  • ****
  • Posts: 464
  • Availability: 30%
Re: [Plugin] Front-end Admin Edit
« Reply #2 on: June 18, 2013, 08:54:58 am »
Glad you like it. :-)

trains58554

  • Osclass contributor
  • Hero Member
  • *****
  • Posts: 3642
  • osCanyon, the class of Osclass
Re: [Plugin] Front-end Admin Edit
« Reply #3 on: June 18, 2013, 09:35:52 am »
Hi gilden,

Nice work. :)

I looked at your code and I was wondering why you do not just check if the admin user is logged in instead of running the database call?

You could do something like this
if(osc_is_admin_user_logged_in() && osc_is_ad_page()) { ?>

As the admin has to be logged in order to edit the listings.

Just a friendly suggestion. :)

Jay

Gilden

  • Sr. Member
  • ****
  • Posts: 464
  • Availability: 30%
Re: [Plugin] Front-end Admin Edit
« Reply #4 on: June 18, 2013, 10:03:37 am »
Thanks for the suggestion. I thought about that, but since the logins are managed separately (for front-end and admin CP) I thought it would not work. I'll try that and update :-)
It's better without an extra database call :-)

Gilden

  • Sr. Member
  • ****
  • Posts: 464
  • Availability: 30%
Re: [Plugin] Front-end Admin Edit
« Reply #5 on: June 19, 2013, 12:28:43 pm »
Jay, I tried your suggestion, but somehow it is not working. Even logged in as admin and as front-end user it does not show.

thedon

  • Sr. Member
  • ****
  • Posts: 341
Re: [Plugin] Front-end Admin Edit
« Reply #6 on: June 20, 2013, 03:22:09 am »
good work

trains58554

  • Osclass contributor
  • Hero Member
  • *****
  • Posts: 3642
  • osCanyon, the class of Osclass
Re: [Plugin] Front-end Admin Edit
« Reply #7 on: June 20, 2013, 08:48:55 am »
hmm I will take another look maybe I over looked something.

Jay

Gilden

  • Sr. Member
  • ****
  • Posts: 464
  • Availability: 30%
Re: [Plugin] Front-end Admin Edit
« Reply #8 on: September 05, 2013, 01:32:10 am »
Plugin updated, just to include a simple help file.
Tested with Osclass 3.1 to 3.2.1, but should work with previous versions as well.

lexosc

  • Sr. Member
  • ****
  • Posts: 344
Re: [Plugin] Front-end Admin Edit
« Reply #9 on: September 05, 2013, 02:02:34 am »
Hey Gilden I really appreciate your contributions! could you please make a guide on how to add a wordpress blog to osclass like you did with http://blog.treasureclassifieds.com ?

Gilden

  • Sr. Member
  • ****
  • Posts: 464
  • Availability: 30%
Re: [Plugin] Front-end Admin Edit
« Reply #10 on: September 05, 2013, 03:23:45 am »
The blog is not linked to Osclass. Just a separate install in a subdomain.

lexosc

  • Sr. Member
  • ****
  • Posts: 344
Re: [Plugin] Front-end Admin Edit
« Reply #11 on: September 05, 2013, 10:53:37 am »
yes but how to edit the wp code to make the header same with osclass?

dev101

  • Osclass Hero
  • Hero Member
  • *
  • Posts: 2118
  • osclass.work
Re: [Plugin] Front-end Admin Edit
« Reply #12 on: September 05, 2013, 11:54:09 am »
Newer wp themes have a built-in editor functionality support inside Wordpress so you can edit header and colors up to a point. Also, if any .png or .jpg files are used, just locate them inside wp-content/themes/your_theme/images (usually it's called images) and replace them with yours, ideally same size in pixels.

Another way is to edit css file(s) manually and some .php templates, which can be time-consuming to make a 1-to-1 match, but it's doable.

lexosc

  • Sr. Member
  • ****
  • Posts: 344
Re: [Plugin] Front-end Admin Edit
« Reply #13 on: September 05, 2013, 01:00:11 pm »
Ok thank you this is the way i knew but i thought maybe there was some better way to do this

Gilden

  • Sr. Member
  • ****
  • Posts: 464
  • Availability: 30%
Re: [Plugin] Front-end Admin Edit
« Reply #14 on: September 05, 2013, 01:07:27 pm »
In my case, the theme was created for that purpose, so I made it similar to the other sections of the site.