ThemeForest

Posts by valendesigns

114 posts
  • Attended a Community Meetup
  • Author had a File in an Envato Bundle
  • Bought between 50 and 99 items
  • Elite Author
  • Envato Staff
  • Exclusive Author
  • Has been a member for 4-5 years
+3 more
valendesigns staff says

I need to update the docs those should have a 2 and not a 1 for the amount of variables being passed, sorry!

114 posts
  • Attended a Community Meetup
  • Author had a File in an Envato Bundle
  • Bought between 50 and 99 items
  • Elite Author
  • Envato Staff
  • Exclusive Author
  • Has been a member for 4-5 years
+3 more
valendesigns staff says

Could anyone explain, how to make Google Fonts available for Typography option? I have done this:
function filter_ot_recognized_font_families( $array, $field_id ) {

  /* only run the filter when the field ID is my_google_fonts_headings */
  if ( $field_id == 'my_google_fonts_headings' ) {
    $array = array(
      'sans-serif'    => 'sans-serif',
      'open-sans'     => '"Open Sans", sans-serif',
      'droid-sans'    => '"Droid Sans", sans-serif'
    );
  }

  return $array;

}
add_filter( 'ot_recognized_font_families', 'filter_ot_recognized_font_families', 10, 1 );
But don’t understand how this could help.
add_filter( 'ot_recognized_font_families', 'filter_ot_recognized_font_families', 10, 2 );
114 posts
  • Attended a Community Meetup
  • Author had a File in an Envato Bundle
  • Bought between 50 and 99 items
  • Elite Author
  • Envato Staff
  • Exclusive Author
  • Has been a member for 4-5 years
+3 more
valendesigns staff says



Hi derek,

v2.0.7 breaks everything. There’s an error with the css and js enqueuing I guess…

Basically the scripts URL is a mix of the plugin location and the ot folder location of the theme…

Parker
I highly doubt it’s broken. In what way do you use the plugin, as a plugin or in theme more? I need to know more about your setup. Also, if you send me a copy of your theme to derek[at]valendesigns.com I’ll tell you exactly why it’s not working.

Hi Derek,

well, v2.0.6 is working… so. I’m using ot in theme mode (no plugin in plugins folder, only in theme root) as for your instructions. Everything was working fine before. The settings array is created by me (not generated) and it’s correct.

My theme isn’t published yet, so I’m not in a hurry, I’m just testing everything to help you out.

In my previous post I’ve explained what’s causing the error. If nobody will experience this in the next hours I’ll send you my theme eventually.

I don’t want to overcharge you now, you should be busy already ;)

Parker

Please just send it I need to see whats happening so I can either fix it or make a suggestion on how you could change your theme. Either way it’s now or later and I’m not going to have time later this week to focus on OT, I need to make this progress now.

114 posts
  • Attended a Community Meetup
  • Author had a File in an Envato Bundle
  • Bought between 50 and 99 items
  • Elite Author
  • Envato Staff
  • Exclusive Author
  • Has been a member for 4-5 years
+3 more
valendesigns staff says

Hi derek,

v2.0.7 breaks everything. There’s an error with the css and js enqueuing I guess…

Basically the scripts URL is a mix of the plugin location and the ot folder location of the theme…

Parker

I highly doubt it’s broken. In what way do you use the plugin, as a plugin or in theme more? I need to know more about your setup. Also, if you send me a copy of your theme to derek[at]valendesigns.com I’ll tell you exactly why it’s not working.

114 posts
  • Attended a Community Meetup
  • Author had a File in an Envato Bundle
  • Bought between 50 and 99 items
  • Elite Author
  • Envato Staff
  • Exclusive Author
  • Has been a member for 4-5 years
+3 more
valendesigns staff says

Hey Guys,

I’m working on a way to export the theme options to a PHP file, should be available early this coming week. It’s a bit more than just a var_export() as I want it to include the add_action() and build a complete file like the demo-theme-options.php but with your saved settings so all you need to do is include it. You should test it and check it for errors before you use though just to be safe.

Cheers, Derek

114 posts
  • Attended a Community Meetup
  • Author had a File in an Envato Bundle
  • Bought between 50 and 99 items
  • Elite Author
  • Envato Staff
  • Exclusive Author
  • Has been a member for 4-5 years
+3 more
valendesigns staff says



valendesigns, sorry I am bothering u with all these questions, why not just make image width and height as a default feature in your plugin? Thanks.

It’s OK you’re asking questions I don’t mind. As far as my opinion on your feature request, you might be making assumptions that everyone needs to know the image height and width. OptionTree wasn’t created to do everything for you it’s meant to be extendable. You can always create your own custom option types if you need niche options and hook into the validation filter to keep them clean in the DB.

Quick question though, why do you need the height and width, why is that important to you?
At first these attributes speed up the rendering of the page and for the second I need my logo to be aligned center :)

You can center align it with CSS . I believe this will do the trick.

.your-image-class {
  display: block;
  margin: 0 auto;
}
114 posts
  • Attended a Community Meetup
  • Author had a File in an Envato Bundle
  • Bought between 50 and 99 items
  • Elite Author
  • Envato Staff
  • Exclusive Author
  • Has been a member for 4-5 years
+3 more
valendesigns staff says

valendesigns, one more question. In case of Step 1: Include the plugin & turn on theme mode, should I still wrap my code with function_exists? Thanks.

If you’re including it in your theme you do not need to use function_exists.

114 posts
  • Attended a Community Meetup
  • Author had a File in an Envato Bundle
  • Bought between 50 and 99 items
  • Elite Author
  • Envato Staff
  • Exclusive Author
  • Has been a member for 4-5 years
+3 more
valendesigns staff says

valendesigns, sorry I am bothering u with all these questions, why not just make image width and height as a default feature in your plugin? Thanks.

It’s OK you’re asking questions I don’t mind. As far as my opinion on your feature request, you might be making assumptions that everyone needs to know the image height and width. OptionTree wasn’t created to do everything for you it’s meant to be extendable. You can always create your own custom option types if you need niche options and hook into the validation filter to keep them clean in the DB.

Quick question though, why do you need the height and width, why is that important to you?

114 posts
  • Attended a Community Meetup
  • Author had a File in an Envato Bundle
  • Bought between 50 and 99 items
  • Elite Author
  • Envato Staff
  • Exclusive Author
  • Has been a member for 4-5 years
+3 more
valendesigns staff says

valendesigns, what about my question, any thoughts?

You need to get the attachment ID from the URL . Try this and see if it helps.

http://wordpress.stackexchange.com/questions/6645/turn-a-url-into-an-attachment-post-id
114 posts
  • Attended a Community Meetup
  • Author had a File in an Envato Bundle
  • Bought between 50 and 99 items
  • Elite Author
  • Envato Staff
  • Exclusive Author
  • Has been a member for 4-5 years
+3 more
valendesigns staff says

I just want to throw it out there that I was vocal about the upgrade and asked for testers here and on twitter in advance and with plenty of notice before going live. Unfortunately, not everyone tested their themes. I am sincerely apologetic for the compatibility issues, it sucks I know. It’s just unfortunate that the awesomeness is being highjacked by this snafu, and is taking away from how much of an improvement the plugin really is. That’s a bit upsetting, but I’ll get over it.

On to more important matters. I have not stopped working on trying to find a fix since this started. As you can see, I’ve pushed out 6 patches in an attempt to make it stable, and about to push out another one that will hopefully fix some themes, I can’t say all because I’m only aware of the issues you tell me about or I get from installing one of your themes and finding the point where it’s breaking. As of 20 minutes ago I believe I have found a fix for Cudazi themes and will push it live once I’ve got a few other people to test it. The updated code is on the development branch over at github.

https://github.com/valendesigns/option-tree/tree/development

Cheers, Derek

by
by
by
by
by