Home Download Buy Blog Forum Support

How to set variables like TM_XHTML??

How to set variables like TM_XHTML??

Postby landtax on Tue Feb 16, 2010 12:07 pm

Hi,

I'm using the HTML bundle and by default it does not generate XHTML code. It does when the variable TM_XHTML is set to "/".
it is explained here: http://raven-seo-tools.com/blog/2949/ho ... n-textmate

Well.. i don't know how to continue with that. Is it possible in sublime? Am I missing something?

Any help is appreciated.

Thanks in advance.
Santi
landtax
 
Posts: 4
Joined: Thu Feb 11, 2010 3:57 pm

Re: How to set variables like TM_XHTML??

Postby EJ12N on Tue Feb 16, 2010 6:05 pm

I don't think you can set any TM variables right now with the exception to "some" of them for snippet functionality ex: TM_SELECTED_TEXT

anyways, I am guessing you are referring by default sublime doesn't close single tags such as BR and IMG or INPUT, easy fix just edit the following file
%AppData%\Sublime Text\Packages\HTML\unclosed tag.sublime-snippet
put this in there
Code: Select all
<snippet>
   <content>&lt;${PARAM1} /&gt;$0</content>
</snippet>


Notice the "/" before the &gt;
, now it will insert the <br /> ;)
and all of these tags too: br|button|embed|hr|input|meta|option|param

You might be interested in the following plugins, I highly recommend 'em :)

http://bitbucket.org/sublimator/webdeve ... /wiki/Home
http://bitbucket.org/sublimator/zencoding/wiki/Home
EJ12N
 
Posts: 281
Joined: Tue Apr 21, 2009 5:23 pm

Re: How to set variables like TM_XHTML??

Postby landtax on Fri Feb 19, 2010 7:16 am

Really thanks a lot. :)

This editor is getting even better everyday. WOW!
landtax
 
Posts: 4
Joined: Thu Feb 11, 2010 3:57 pm

Re: How to set variables like TM_XHTML??

Postby EJ12N on Fri Feb 19, 2010 4:25 pm

landtax wrote:Really thanks a lot. :)

This editor is getting even better everyday. WOW!

You bet ;)
EJ12N
 
Posts: 281
Joined: Tue Apr 21, 2009 5:23 pm

Re: How to set variables like TM_XHTML??

Postby Marin on Thu Mar 29, 2012 2:39 pm

I've just came across this forum post
viewtopic.php?f=3&t=2450

a .tmPreferences file (stored in your package/user folder) would do too!
Marin
 
Posts: 5
Joined: Tue Mar 27, 2012 9:51 am


Return to General Discussion

Who is online

Users browsing this forum: danpyq and 18 guests