[Pro] Clean up the code

I finished desining my website (for the time being). When I let a professionel website engineer look at the code he told me it is a mess. The design codes (that is about 80%) at each page starts at the top of the page. The disadvantage is that the real content is probably not seen by crawlers. So he advised me to dump all design code in a directory and use a “script” to call for the code when necesary. This would clean up the the code on the content containing page considerably. Is there an Freewayaction to do this ? (why is Freeway not designed to do this automatically ?). If there is no Freewayaction is there a tutorial how to do this manually ?


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

I’m sorry … just wet my pants here :slight_smile:


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

The disadvantage is that the real content is probably not seen by crawlers.

Crawlers know the difference between style code and page content.

But if you want style sheets externally then there are actions for that.

Start with Externalize by Tim Plumb http://www.freewayactions.com/

David


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

If you are looking for that Action you’ll find it here;
http://www.freewayactions.com/test/externalize/
It will extract as much of the styles and JavaScript from the page as it can and will leave you with as clean an HTML page as it can produce.

Artivideo, can you be a little more specific and maybe show us a before and after page please? It’ll be good to see how you’ve cleaned (or intend to clean) the page content up.
Regards,
Tim.

On 2 Nov 2012, at 21:42, DeltaDave wrote:

Start with Externalize by Tim Plumb http://www.freewayactions.com/


FreewayActions.com - Freeware and commercial Actions for Freeway Express & Pro - http://www.freewayactions.com


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

On 2 Nov 2012, 8:57 pm, Richard van Heukelum wrote:

I’m sorry … just wet my pants here :slight_smile:

Sorry to be so ignorantly literal. What is that supposed to mean? Thanks!


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Hi Artivideo

What your website engineer is probably talking about is in freeway the main bulk of the positioning and some of the inspector based styling attributes, of each item you construct is inserted as an inline style.

Styles you create using the edit styles method are inserted into either the HEAD part of the html document or (if you have external style sheets option turned on) into an external style sheet.

Even though this method of adding styles is now not in favour by the general web constructing public, it is in fact perfectly valid, and oddly enough if you were constructing an html emailer, you would absolutely want all your styles to be inline styles. (So the exact opposite of what your engineer described.)

Freeway is quite capable of creating non inline styled content, and there are a number of actions that can help you. Tim Plumbs is without doubt the best there is and this is especially true if you don’t know much about creating, naming and ordering styles. The action will run through your document and move all those styles for you.
There other actions like Advanced inline style mover and the Classify action which can work hand in hand with Tim’s action which will reduce the amount of styles necessary to to be physically written, but they do require you to understand a fair degree of styling and html construction. So if you are a novice in those areas, then use Tim’s action by its own as it will get you 95% of the way to what you want.

I hope that helps and kind regards
Max


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Thanks I will try Tim’s action. Hope the website will still work afterwards.


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Hope the website will still work afterwards.

Oh, ye of little faith!

You can always remove it to revert back to standard FW code.

David


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Ok I tried the externalize action and got 4 issues :

  1. website becomes slow (loading of the pages when going from one page to the other)
  2. PHP page doent work anymore
  3. the ccs file are not placed in the css directory but in the root of the site directory
  4. the design of my blog page is affected

I returned to my previous version (made a backup before applying externalize. So there is some work to do for Tim. Not surpirised since it is still a beta version. Will wait untill the released version is published.


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

I’m working with the Externalize beta action too. At first I was
disappointed that the css file didn’t go in the css folder, but then I
realized that the page code the action is moving is written differently by
Freeway Pro and putting it in the css folder would break all the relative
links. So, barring any cooperation with the FWP programmers, I think it’s
the best compromise available.

I’ve also encountered some other issues with the action giving
unpredictable results, but I’m working through those. Your other issues may
be from that as well. I advise caution when using it with other actions
that write css code in the page head. Also, it seems best applied as a last
step, not an early step.


Ernie Simpson

On Mon, Nov 12, 2012 at 4:22 AM, Artivideo email@hidden wrote:

Ok I tried the externalize action and got 4 issues :

  1. website becomes slow (loading of the pages when going from one page to
    the other)
  2. PHP page doent work anymore
  3. the ccs file are not placed in the css directory but in the root of the
    site directory
  4. the design of my blog page is affected

I returned to my previous version (made a backup before applying
externalize. So there is some work to do for Tim. Not surpirised since it
is still a beta version. Will wait untill the released version is published.


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options