Wordpress Themes - WP Forum at BFA
Click Here To DONATE! Support the theme development, get more attention and additional benefits based on your donation level. Your forum name will be highlighted.

Wordpress Themes - WP Forum at BFA » WordPress Themes » Atahualpa 3 Wordpress theme » New Versions, & Updating »

3.6.7 This is awful. I have a ton of custom php code


Build custom WP THEMES, without
coding.
Click here for THEMEFRAME

From the author of Atahualpa, the #1 most
downloaded (700,000+) theme @ wordpress.org
  #1  
Old May 11, 2011, 01:09 PM
wittyusername
 
61 posts · Jan 2011
muddling my way though a career.
This is awful. I have a ton of custom php code in many ata installs. Looks like i won't be upgrading any time soon.

2. how am i supposed to customize the theme in the future? put my php directly into the index.php (or whatever) template?
__________________
Wordpress 3.2.1 | Atahualpa 3.7.3 | Webfaction Hosting
  #2  
Old May 12, 2011, 01:03 PM
johnh44's Avatar
johnh44
 
34 posts · Nov 2010
Portland, Oregon
Send a message via Skype™ to johnh44
Quote:
Originally Posted by wittyusername
This is awful. I have a ton of custom php code in many ata installs. Looks like i won't be upgrading any time soon. ...
YIKES! Same here ... does this even include such php as Wordpress's own references, such as this in the CSS INSERTS area:

HTML Code:
background: url('<?php bloginfo('template_directory'); ?>/images/bullets/round-gray.gif') no-repeat 0 7px;
__________________
John Hamlin, Nozzl.Com Founder & VP Operations.
Also, retired Newsroom Technology Director, The Oregonian, Portland, Oregon, USA.
  #3  
Old May 12, 2011, 01:05 PM
lmilesw's Avatar
lmilesw
 
10,053 posts · Jul 2009
Central New York State USA
Yes it does. You need to use full paths now.
__________________
~Larry (CNY Web Designs)
This site should be a membership site since it so full of good stuff.
Please consider donating which gives you access to even more good stuff.
  #4  
Old May 12, 2011, 05:40 PM
johnh44's Avatar
johnh44
 
34 posts · Nov 2010
Portland, Oregon
Send a message via Skype™ to johnh44
Quote:
Originally Posted by lmilesw
Yes it does. You need to use full paths now.
Bummer. Not you guys, of course -- victims of the WordPress tightening like the rest of us. Just makes upgrades more difficult because of need to enter new directory names for URLs in the CSS Inserts.

Any reason the atahualpa directory under themes cannot retain the same name? E.G. ayahualpa.
__________________
John Hamlin, Nozzl.Com Founder & VP Operations.
Also, retired Newsroom Technology Director, The Oregonian, Portland, Oregon, USA.
  #5  
Old May 12, 2011, 05:50 PM
lmilesw's Avatar
lmilesw
 
10,053 posts · Jul 2009
Central New York State USA
It can retain that name but I like to give it a new name so I can always switch back to a previous version if I have problems. It creates a bit more work in upgrading but gives me peace of mind.
__________________
~Larry (CNY Web Designs)
This site should be a membership site since it so full of good stuff.
Please consider donating which gives you access to even more good stuff.
  #6  
Old May 12, 2011, 06:28 PM
johnh44's Avatar
johnh44
 
34 posts · Nov 2010
Portland, Oregon
Send a message via Skype™ to johnh44
Quote:
Originally Posted by lmilesw
It can retain that name but I like to give it a new name so I can always switch back to a previous version if I have problems. It creates a bit more work in upgrading but gives me peace of mind.
Makes sense, especially when a backstep is needed

However, on this whole issue I'm really discouraged. There is SO MUCH PHP in the theme's editable insert areas. Losing all this is a major setback for me as well as for the amazing customizability of Atahualpa. I have multiple templates and see no reasonable way to move beyond 3.6.4 without weeks of work (weeks I don't have). I know I'm whining, but it sure would be nice if there were a detailed to-do- list for this upgrade -- especially as to how if affects the now-defunct "Style & Edit CENTER COLUMN" where multpile <?php is in use.

An idea: Any chance this section could interpret shortcodes? And if so, y'all could park those items in [shortcodes], such as this default ata code: (???)

HTML Code:
<?php /* For MULTI post pages if activated at ATO -> Next/Previous Navigation: */ bfa_next_previous_page_links('Top'); ?> <?php if( is_category() AND function_exists('page2cat_output')) { page2cat_output($cat); } ?>
If not, where exactly in the templates would each of these code snippets be put?
__________________
John Hamlin, Nozzl.Com Founder & VP Operations.
Also, retired Newsroom Technology Director, The Oregonian, Portland, Oregon, USA.
  #7  
Old May 12, 2011, 09:06 PM
lmilesw's Avatar
lmilesw
 
10,053 posts · Jul 2009
Central New York State USA
Honestly I would just stay with 3.6.4.
__________________
~Larry (CNY Web Designs)
This site should be a membership site since it so full of good stuff.
Please consider donating which gives you access to even more good stuff.
  #8  
Old May 13, 2011, 08:42 AM
Flynn's Avatar
Flynn
 
3,754 posts · Oct 2008
Munich, Germany
It's not the end all to anything PHP though

Raw PHP isn't possible anymore but PHP functions that are known beforehand can be parsed as text string and then executed as I added in 3.6.7 for the function

<?php bfa_widget_area('....'); ?>

I'll add this for a whole bunch of PHP functions so hopefully you'll be able to upgrade smoothly to 3.6.8 WITH custom PHP code

PHP code with logic (IF/ELSE FOREACH WHILE) won't work though, only simple PHP one liners, 1 function with or without parameters:

<?php functionname('paremeter1=Paramater 1&parameter2=Parameter 2&.......'); ?>

This should however cover most of the custom PHP that is being used in Atahualpa
  #9  
Old May 13, 2011, 09:31 AM
lmilesw's Avatar
lmilesw
 
10,053 posts · Jul 2009
Central New York State USA
With the ability to add a new widget area You can add a New Widget area in various places such as ATO>Add HTML/CSS Inserts>HTML Inserts: Body Top or ATO>Style & Edit Header Area>Configure Header Area and then use a PHP aware widget in those areas.
__________________
~Larry (CNY Web Designs)
This site should be a membership site since it so full of good stuff.
Please consider donating which gives you access to even more good stuff.
  #10  
Old May 13, 2011, 04:41 PM
johnh44's Avatar
johnh44
 
34 posts · Nov 2010
Portland, Oregon
Send a message via Skype™ to johnh44
Quote:
Originally Posted by Flynn
It's not the end all to anything PHP though

... hopefully you'll be able to upgrade smoothly to 3.6.8 WITH custom PHP code
This sounds good. Also, I've made quite a few custom templates that are essentially the same (copies of index.php) but with different combinations of sidebars. Rather than make changes in multiple templates, what you are making sounds like a solution or partial solution. Creating an include file for what's unchanging in multiple templates is also a game plan ...

Meanwhile, I'm with lmilesw:

Quote:
Honestly I would just stay with 3.6.4.
__________________
John Hamlin, Nozzl.Com Founder & VP Operations.
Also, retired Newsroom Technology Director, The Oregonian, Portland, Oregon, USA.

Last edited by juggledad; May 13, 2011 at 08:46 PM.
  #11  
Old May 13, 2011, 09:31 PM
lmilesw's Avatar
lmilesw
 
10,053 posts · Jul 2009
Central New York State USA
I should have said "In your case I would just stay with 3.6.4 for now". Going with 3.6.7 makes sense for a great majority of people.
__________________
~Larry (CNY Web Designs)
This site should be a membership site since it so full of good stuff.
Please consider donating which gives you access to even more good stuff.
  #12  
Old May 13, 2011, 10:41 PM
vincent
 
64 posts · Nov 2010
Is creating an ATA plugin an option to enable PHP into the theme's editable insert areas?

- Vincent
  #13  
Old May 20, 2011, 03:00 PM
sudipto's Avatar
sudipto
 
15 posts · Feb 2011
LetusBuzz.com Powered by Wordpress and Atahualpa
Hi John,
I have given a solution to reactivate PHP in this thread
http://forum.bytesforall.com/showthr...&highlight=php

But you need to edit the functions.php file.

I totally agree with Vincent that we can create a plugin to activate php in Atahualpa.

Like the theme can contain a pluggable functions like wordpess has that can be called from plugins. Well thats just a thought. Anyways I trust Flynn and he will definitely come up with something.

But I am sticking to 3.6.4 because i have custom code in the loop section that has been removed in 3.6.7. Hope Flynn activates it back again soon

Last edited by sudipto; May 20, 2011 at 03:05 PM.
  #14  
Old May 26, 2011, 02:37 PM
rvconnelly
 
13 posts · May 2010
Henderson, NV
Quote:
Originally Posted by Flynn
It's not the end all to anything PHP though

Raw PHP isn't possible anymore but PHP functions that are known beforehand can be parsed as text string and then executed as I added in 3.6.7 for the function

<?php bfa_widget_area('....'); ?>

I'll add this for a whole bunch of PHP functions so hopefully you'll be able to upgrade smoothly to 3.6.8 WITH custom PHP code

PHP code with logic (IF/ELSE FOREACH WHILE) won't work though, only simple PHP one liners, 1 function with or without parameters:

<?php functionname('paremeter1=Paramater 1&parameter2=Parameter 2&.......'); ?>

This should however cover most of the custom PHP that is being used in Atahualpa
I am currently using 3.6.4 (fyi... I have some html & css knowledge & a little js, but no php). I have the following code added to the Atahualpa option "FOOTER: Single Post Pages".

<span class='st_twitter' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' displayText='Twitter'></span>

The above code is an example of 5 social media buttons that display on Single Post Pages BUT NOT on Multi Post Pgs or the Home Page (I had to turn off the ShareThis plugin's auto insert capability to do this. They place it on all post pages).

This is currently working with 3.6.4.... when a social media button is clicked, it uses the title/permalink of the post in the text link, saving the site-visitor the trouble of typing it out (see www.renderyourvision.com).

I assume this php functionality will be disabled if/when I upgrade to a more current version of Atahualpa.

My question is, if I create a widget "area" and place it in FOOTER: SINGLE POST PAGES, will the php then still work in versions 3.6.7 and up? -Thank you.
  #15  
Old May 26, 2011, 04:19 PM
lmilesw's Avatar
lmilesw
 
10,053 posts · Jul 2009
Central New York State USA
I have had success doing what you mention. I would recommend a manual upgrade so you can test and if there are issues you can just switch back to 3.6.4.
__________________
~Larry (CNY Web Designs)
This site should be a membership site since it so full of good stuff.
Please consider donating which gives you access to even more good stuff.
  #16  
Old May 26, 2011, 06:32 PM
rvconnelly
 
13 posts · May 2010
Henderson, NV
Thanks for the feedback, Larry, but I was wondering if Flynn could briefly comment as to whether this string is the type he was talking about in his post #8, above:

<span class='st_twitter' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' displayText='Twitter'></span>


Here's a snippet of his post:

Quote:
Originally Posted by Flynn
... only simple PHP one liners, 1 function with or without parameters:
<?php functionname('paremeter1=Paramater 1&parameter2=Parameter 2&.......'); ?>
This should however cover most of the custom PHP that is being used in Atahualpa
__________________
Render your vision
TheRVCblog.com
  #17  
Old May 26, 2011, 06:39 PM
juggledad's Avatar
juggledad
 
21,965 posts · Mar 2009
OSX 10.8.5 WP 3.8.x Atahualpa 3.7.x Safari 6.x Firefox 25 XP
I believe those are the types of things he is talking about. However, there is no way every function could be checked and programmed in.
__________________
If you like my help, please consider donating. I am happy to provide greater detail on this and other topics if you hire me. Please send detailed support requests to me as a private message, thank you.
Juggledad | Forum Moderator/Support
  #18  
Old May 26, 2011, 07:44 PM
rvconnelly
 
13 posts · May 2010
Henderson, NV
Ok. Thanks. I will test it after I upgrade to 3.6.7. If it works, I will confirm in a post (for anyone else that might be using the shareThis plugin with Atahualpa theme). By the way, awesome theme. You guys do GREAT work. Thanks again.
__________________
Render your vision
TheRVCblog.com
  #19  
Old Jun 2, 2011, 05:35 PM
rvconnelly
 
13 posts · May 2010
Henderson, NV
I have this code loaded in EDIT POST/PAGE INFO ITEMS > FOOTER: SINGLE POST PAGES:

<span class='st_twitter' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' displayText='Twitter'></span>
<span class='st_facebook' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' displayText='Facebook'></span>
<span class='st_linkedin' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' displayText='LinkedIn'></span>
<span class='st_email' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' displayText='Email'></span>
<span class='st_sharethis' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' displayText='ShareThis'></span>


It works with Ata 3.6.4 (WP 3.1.3) but not in Ata 3.6.7 (WP 3.1.3). It picks up the post title and loads it into the social media share screen after the user logs in. ShareThis.com is a pretty popular Wordpress plugin. I have double checked the plugin settings so I assume that this is due to the WP requirement to remove PHP functionality.

Can this type of simple PHP function be included as an option in 3.6.8?
__________________
Render your vision
TheRVCblog.com
  #20  
Old Jun 2, 2011, 06:20 PM
juggledad's Avatar
juggledad
 
21,965 posts · Mar 2009
OSX 10.8.5 WP 3.8.x Atahualpa 3.7.x Safari 6.x Firefox 25 XP
do a forum search for 'What PHP functions do you want to see as options in 3.6.8?'
__________________
If you like my help, please consider donating. I am happy to provide greater detail on this and other topics if you hire me. Please send detailed support requests to me as a private message, thank you.
Juggledad | Forum Moderator/Support
  #21  
Old Jun 2, 2011, 09:11 PM
ymf
 
61 posts · May 2009
I don't have any of my own php code in the options, yet I somehow have some php code there, as seen in the following extract from the Export of the current Atahualpa settings:

Code:
"content_above_loop":"<?php \/* For MULTI post pages if activated at ATO -> Next\/Previous Navigation: *\/\r\nbfa_next_previous_page_links('Top'); ?>\r\n\r\n<?php \/* For the plugin Page2Cat http:\/\/wordpress.org\/extend\/plugins\/page2cat\/ *\/\r\nif( is_category() AND function_exists('page2cat_output')) { page2cat_output($cat); } ?>",

"content_inside_loop":"<?php \/* For SINGLE post pages if activated at ATO -> Next\/Previous Navigation: *\/\r\nbfa_next_previous_post_links('Top'); ?>\r\n\r\n<?php \/* Post Container starts here *\/\r\nif ( function_exists('post_class') ) { ?>\r\n<div <?php if ( is_page() ) { post_class('post'); } else { post_class(\"$odd_or_even\"); } ?> id=\"post-<?php the_ID(); ?>\">\r\n<?php } else { ?>\r\n<div class=\"<?php echo ( is_page() ? 'page ' : '' ) . $odd_or_even . ' post\" id=\"post-'; the_ID(); ?>\">\r\n<?php } ?>\r\n\r\n<?php bfa_post_kicker('<div class=\"post-kicker\">','<\/div>'); ?>\r\n\r\n<?php bfa_post_headline('<div class=\"post-headline\">','<\/div>'); ?>\r\n\r\n<?php bfa_post_byline('<div class=\"post-byline\">','<\/div>'); ?>\r\n\r\n<?php bfa_post_bodycopy('<div class=\"post-bodycopy clearfix\">','<\/div>'); ?>\r\n\r\n<?php bfa_post_pagination('<p class=\"post-pagination\"><strong>'.__('Pages:','atahualpa').'<\/strong>','<\/p>'); ?>\r\n\r\n<?php bfa_post_footer('<div class=\"post-footer\">','<\/div>'); ?>\r\n\r\n<\/div><!-- \/ Post -->",

"content_below_loop":"<?php \/* Displayed on SINGLE post pages if activated at ATO -> Next\/Previous Navigation: *\/\r\nbfa_next_previous_post_links('Middle'); ?>\r\n\r\n<?php \/* Load Comments template (on single post pages, and static pages, if set on options page): *\/\r\nbfa_get_comments(); ?>\r\n\r\n<?php \/* Displayed on SINGLE post pages if activated at ATO -> Next\/Previous Navigation: *\/\r\nbfa_next_previous_post_links('Bottom'); ?>\r\n\t\t\r\n<?php \/* Archives Pages. Displayed on a specific static page, if configured at ATO -> Archives Pages: *\/\r\nbfa_archives_page('<div class=\"archives-page\">','<\/div>'); ?>\r\n\t\t\t\r\n<?php \/* Displayed on MULTI post pages if activated at ATO -> Next\/Previous Navigation: *\/\r\nbfa_next_previous_page_links('Bottom'); ?>",

"content_not_found":"<h2><?php _e('Not Found','atahualpa'); ?><\/h2>\r\n<p><?php _e(\"Sorry, but you are looking for something that isn't here.\",\"atahualpa\"); ?><\/p>",
I wonder if this php code will be nicely handled when upgrading to 3.7?
  #22  
Old Jun 3, 2011, 04:05 AM
juggledad's Avatar
juggledad
 
21,965 posts · Mar 2009
OSX 10.8.5 WP 3.8.x Atahualpa 3.7.x Safari 6.x Firefox 25 XP
yfradkin - If you didn't have modifications to it, it will run fine, that code is now in index.php.
__________________
If you like my help, please consider donating. I am happy to provide greater detail on this and other topics if you hire me. Please send detailed support requests to me as a private message, thank you.
Juggledad | Forum Moderator/Support
  #23  
Old Jun 3, 2011, 05:35 PM
rvconnelly
 
13 posts · May 2010
Henderson, NV
Quote:
Originally Posted by rvconnelly
I have this code loaded in EDIT POST/PAGE INFO ITEMS > FOOTER: SINGLE POST PAGES:

<span class='st_twitter' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' displayText='Twitter'></span>
<span class='st_facebook' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' displayText='Facebook'></span>
<span class='st_linkedin' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' displayText='LinkedIn'></span>
<span class='st_email' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' displayText='Email'></span>
<span class='st_sharethis' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' displayText='ShareThis'></span>


It works with Ata 3.6.4 (WP 3.1.3) but not in Ata 3.6.7 (WP 3.1.3). It picks up the post title and loads it into the social media share screen after the user logs in. ShareThis.com is a pretty popular Wordpress plugin. I have double checked the plugin settings so I assume that this is due to the WP requirement to remove PHP functionality.

Can this type of simple PHP function be included as an option in 3.6.8?
Yesterday I asked this question. The reply was to "do a forum search for 'What PHP functions do you want to see as options in 3.6.8?'" I had already seen that thread but wasn't sure this question belonged there (I don't have any php exp; which I explained in #14).

As suggested by Juggledad, I re-posted my question in the other thread. I included as much relevant detail as possible thinking that would be helpful. My post was then summarily deleted by Juggledad for being inappropriate for that thread. Puzzling.
  #24  
Old Jun 3, 2011, 05:58 PM
lmilesw's Avatar
lmilesw
 
10,053 posts · Jul 2009
Central New York State USA
You could perhaps put a new widget area in the footer area and then use a php aware widget to populate the widget area.
__________________
~Larry (CNY Web Designs)
This site should be a membership site since it so full of good stuff.
Please consider donating which gives you access to even more good stuff.
  #25  
Old Jun 3, 2011, 07:22 PM
juggledad's Avatar
juggledad
 
21,965 posts · Mar 2009
OSX 10.8.5 WP 3.8.x Atahualpa 3.7.x Safari 6.x Firefox 25 XP
Your question was
Quote:
Can this type of simple PHP function be included as an option in 3.6.8?
so I pointed you to the thread asking what FUNCTIONS were requested for 3.6.8 - In you case you wanted two functions, and everything else was irrelevant, so I removed it. This way the developer can see the functions, not spend his time trying to extract that form a long post.

So the answer to your question is 'Hopefully it will get into 3.6.8'
__________________
If you like my help, please consider donating. I am happy to provide greater detail on this and other topics if you hire me. Please send detailed support requests to me as a private message, thank you.
Juggledad | Forum Moderator/Support

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Pls help me change this code<title><?php bloginfo('name'); ?><?php wp_title(); ?></ti tobywinn Header configuration & styling 1 Nov 18, 2011 11:51 AM
Custom Read More with PHP adum Excerpts, Read more, Pagination 14 Sep 20, 2010 06:25 AM
Custom php in a page ccw Atahualpa 3 Wordpress theme 4 Apr 5, 2010 09:42 AM
Help! My Atahualpa blog has awful W3C validation. Tomo9 Plugins & Atahualpa 0 Sep 10, 2009 01:19 PM
How to insert php code into Byline JakeThePeg Post-Kicker, -Byline & -Footer 1 Aug 27, 2009 06:16 PM


All times are GMT -6. The time now is 04:32 PM.


Powered by vBulletin® Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.