• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Liutauras Vilda
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Saloon Keepers:
  • Scott Selikoff
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
  • Frits Walraven
Bartenders:
  • Stephan van Hulst
  • Carey Brown

Velocity

 
Ranch Hand
Posts: 411
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello, ranchers

Could you please inform me how can I update body.html using velocity, if it's included inside index.html..

Thanks,

JML
 
Ranch Hand
Posts: 2308
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Velocity has got nothing to do with html.Its just an templating frameowrk.Probably your framework/project is using velocity to generate the html and without having the code of that project this question cannot be answered.
 
Jamal Hasanov
Ranch Hand
Posts: 411
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have 2 files:
index.html
head.html

index.html includes head.html. Inside head.html I have tags like $invoice_amount, $user_name, etc.

I use VelocityServlet for replacing this tags with values. But I must return index.html to client... How to force Velocity to change head.html inside index.html?
 
Rahul Bhattacharjee
Ranch Hand
Posts: 2308
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Jamal Hasanov:
I have 2 files:
index.html
head.html

index.html includes head.html. Inside head.html I have tags like $invoice_amount, $user_name, etc.

I use VelocityServlet for replacing this tags with values. But I must return index.html to client... How to force Velocity to change head.html inside index.html?



I still could not get the problem.
index.html and head.html are basically vm files or the templates files.
You ca use
#parse("head.html")
within index.html to get the required result.
 
Replace the word "snake" with "danger noodle" in all tiny ads.
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic