views:

1057

answers:

6

How do I get smarty syntax highlighting in Eclipse PDT?

The only project I was able to find is SmartyPDT, but it's outdated and isn't working with my current Eclipse install (PDT All in one, with Eclipse 3.5).

EDIT: I recently found this post asking the same question from a long time ago. But the plugin linked in the accepted answer there is out of date now.

EDIT: removed "(no accepted answer)" from title. it was misleading.

A: 

what does Aptana use? I think its Smarty enabled..and it integrates with Eclipse PDT and the other choice is Zend Studio which is built on top of Eclipse PDT

Fred Grott
i tried installing Aptana as a plugin in Eclipse, but I don't see any Smarty support. any ideas?
pocketfullofcheese
A: 

I think I have a post about PDT support via Eclipse at hackedlabs.wordpess.com it would be December 2009 or January 2010.

Fred Grott
It's a shame you're too busy to dig out the URL of your own article.
APC
ahem aptana also has guides on how to install it as an Eclipse plugin..and both come up in google search on the first page..
Fred Grott
A: 

I suggest special Smarty plug-in for FREE PHP IDE - Codelobster PHP Edition. It has highlighting, auto-complete and context help for Smarty.

Rustik
I'm not looking for another IDE. I want smarty highlighting in Eclipse.
pocketfullofcheese
+1  A: 

I've used both SmartyPDT and SSE*.

SmartyPDT is finicky and it took some time for me to get it working. Unfortunately, after an OS reinstall my custom jars don't work anymore, so I've been using SSE.

It is quite basic but better than nothing.

It is described in English at bar54.

Download it from Google's translated version.

Update:

Example of SSE

*I guess this is what it's called, the page is in Japanese.

Michael Robinson
thanks. Will try this out now!
pocketfullofcheese
doesn't do syntax highlight of the smarty stuff, but its a start! thanks.
pocketfullofcheese
I'm not sure what you mean? SSE highlights Smarty stuff for me (updated to include screenshot).Only thing I don't like is it's behaviour with JS syntax, but I usually use Aptana's JS Editor for that anyway.
Michael Robinson
in your screenshot above, everything inside the smarty tags is the same color. What I had previously (with SmartyPDT, back when it worked) would figure out the backticks, the |, smarty function names, strings, etc.
pocketfullofcheese
Ah that is a screen of SSE, as I couldn't easily change SmartyPDT's delimiters it is useless to me. Also it couldn't handle {literal} properly...
Michael Robinson
A: 

About Using Aptana + Eclipse: They removed support for Smarty in Aptana Studio 2 because they were going to "join forces with the eclipse PDT team", but with "unknown schedule as to when or wether smarty support will come to pdt".

Anyways, they also offer to download the "old" Aptana Studio, which works for me like a charm, I wouldn't want to miss smarty support ever again:

https://aptanastudio.tenderapp.com/faqs/installing-aptana-studio/downloading-aptana-studio-151-and-aptana-php

It works in parallel with PDT2, cause for some reason the php support of Aptana is not so good in 1.5.1 - but the smarty support is cheesy :).

craftyfirefox
A: 

Great article about integration Eclipse Helios + PDT + Smarty http://www.ikravets.com/computers-life/programming/2010/09/27/eclipse-helios-pdt-smarty (Use translation to English on this page)

Ivan