Spork Boards

PHP and Unixy stuff...

ARL (Moderator) – March 20, 2008 10:04PM Reply Quote
Hey, hey! I'm looking at sticking my big toe into MySQL and PHP.

Here's the place to share tips/tricks etc and ask dumbass noob questions...

Mokers (Moderator) – November 13, 2010 08:11PM Reply Quote
Formerly Remy Martin
there is an open source library system called koha. It installs just fine on Ubuntu, but since my company only supports Windows and OS X, I have to get it to compile on OS X for our client. iconv comes standard with OS X, but for some reason, perl is not seeing it so I can't build this component.

John Willoughby – November 13, 2010 08:12PM Reply Quote
Cyberdyne Systems Customer Support
It's not in Fink, is it?

tomierna (Admin) – November 13, 2010 09:06PM Reply Quote
Hideously Unnatural
Usually iconv is pathing + versioning problems. It's why PHP bundles their own iconf, IIRC.

In any case, what you need to do is use MacPorts to install the compatible iconv in /opt/local and then make the koha library makefile or configuration point at /opt/local for the iconv libs.

Mokers (Moderator) – November 14, 2010 01:02AM Reply Quote
Formerly Remy Martin
I used the ports version of iconv when I built the earlier versions of koha, but I used an earlier version of the Text::Iconv module. The latest version of koha requires the latest version of Text::Iconv, which for some reason I wasn't able to build. Unfortunately, I don't have another computer with Leopard Server that I can test this install on. I'll recheck my directories once I get to the client again.

And now that I think of it, the make's were complaining that it couldn't find xcode, even though everything else was building correctly, so I am going to reinstall the latest xcode tools as well.

porruka (Admin) – November 14, 2010 12:51PM Reply Quote
The cat has your pipe.
Remy,

Send along the compile lines and .config output, and specific error messages.

[Edit] Posts crossed. If you don't get it figured out with the xcode reinstall, send along the output/commands/etc. There's probably a path definition that needs to be set, or is in conflict and needs to be overridden.



Edited 1 time(s). Last edit at 11/14/2010 12:54PM by porruka.

Mokers (Moderator) – November 14, 2010 11:03PM Reply Quote
Formerly Remy Martin
Thanks. I am not going to be at this client again for at least a couple of weeks, but I'll keep you posted.

Cloudscout – November 16, 2010 08:45PM Reply Quote
Det finnes ikke dårlig vær, bare dårlige klær!
I ended up with an old G4 Mac Mini. I wanted to put 10.5 Server on it but couldn't find a copy. Instead, I'm in the process of installing Ubuntu 10.10. We'll see how well that runs.

Cloudscout – November 16, 2010 09:33PM Reply Quote
Det finnes ikke dårlig vær, bare dårlige klær!
Well, it's installed. I'm a little disappointed to learn that there's no Google Chrome for PowerPC Linux.

Cloudscout – November 16, 2010 10:01PM Reply Quote
Det finnes ikke dårlig vær, bare dårlige klær!
Conclusion: Ubuntu is pretty much useless as a desktop OS on a G4 Mac Mini.

ARL (Moderator) – September 11, 2011 09:45PM Reply Quote
Hmmm...

I'm trying to modify some php templates for a child theme for wordpress. For some reason wordpress is barfing on these files. I was just wondering what text encoding php files should be saved as?

Is UTF-8 ok or should it be something else?

porruka (Admin) – September 12, 2011 12:24AM Reply Quote
The cat has your pipe.
UTF-8 should be fine. What color is the barf? (error messages, description of the particular format of the barf: chunky, splash, projectile, etc)

ARL (Moderator) – September 12, 2011 12:32AM Reply Quote
Page goes blank. Code snippet is here:

<?php if ( !is_page_template ('brandedPage.php') { ?>
	<?php if ( is_front_page() ) { ?>
		< h2 class="entry-title"><?php the_title(); ?></ h2>
	<?php } else { ?>
		< h1 class="entry-title"><?php the_title(); ?></ h1>
	<?php } ?>
<?php } ?>

The only thing I've changed is the wrapper to check whether the page template is brandedPage or not. If it is, it's not meant to display the page title at the top of the page. Page goes blank regardless of whether the template selected is brandedPage or something different.

Spaces have been added so h1 and h2 don't display

Baffled,

TL



Edited 3 time(s). Last edit at 09/12/2011 12:36AM by Tony Leggett.

porruka (Admin) – September 12, 2011 12:38AM Reply Quote
The cat has your pipe.
General debugging: Blank page probably means 500 error which means you should be checking the apache error_log file for the PHP error in question (which leads to rapid resolution, usually).

Specific debugging: You're missing a closing paren on your is_page_template() call.

[EDIT] Technically, you're missing the closing paren on the if conditional surrounding the is_page_template() call...



Edited 1 time(s). Last edit at 09/12/2011 12:40AM by porruka.

ARL (Moderator) – September 12, 2011 12:52AM Reply Quote
Thanks Porruka,

Lynda.com really needs to correct their tutorials.

The third movie in part 14 of this course has the text exactly as I had it - and yet the page somehow inexplicably displays...

porruka (Admin) – September 12, 2011 12:59AM Reply Quote
The cat has your pipe.
I obviously can't speak for the quality of any online tutorials, but this one would likely have been fairly easy to find from the actual error. If you're not friends with your webserver error and access logs, you should introduce yourself. Doing so has the ability to save you significant grief.

Other than that, did the closing paren get you on your way to whatever is next?

ARL (Moderator) – September 12, 2011 01:27AM Reply Quote
The closing paren did the trick.

I didn't look for syntax errors in the php because I was under the assumption that if I copy it exactly like in the tutorial video (where it's shown to work perfectly with that code) it should work.

Where do I get the webserver logs from?

porruka (Admin) – September 12, 2011 01:37AM Reply Quote
The cat has your pipe.
Quote
Tony Leggett
Where do I get the webserver logs from?

Server/config dependent. Apache default is /var/log/httpd IIRC (or maybe /var/log/apache2 these days, and I believe is this on the Mac OS). Very likely to be somewhere else on your server if it's a hosting platform.

ARL (Moderator) – September 12, 2011 01:47AM Reply Quote
Ah, found it amongst the MAMP files.

porruka (Admin) – April 12, 2012 04:24PM Reply Quote
The cat has your pipe.
Ok, so I've hit something that just reinforces my opinion that Linux distro creators simply don't give a fuck about production worlds, but perhaps I'm letting my bias get ahead of me...

would someone be able to school me on a way to get SystemTap running (as in correctly executing, for example, the iotime.stp script from the SystemTap example pool) on CentOS5.5 *without* pulling in the world in terms of software dependencies and full kernel sources?

porruka (Admin) – May 13, 2014 11:46AM Reply Quote
The cat has your pipe.
I happen to have a CVS repository on an older machine, the contents of which I have no clue whether I care about or not. I'd like to remedy that lack of knowledge. Simple, right?

• It's 10.5 Leopard.
• CVS is "broken" there (ocvs seems to be the preferred Mac OS flavor for Leopard)
• ocvs is not present, nor does it *appear* to be being installed with the Xcode 3.1.x command line tools

Where do I find ocvs? My google-fu is clearly failing me.

Sorry, only registered users may post in this forum.

Click here to login