开发者

jQuery string manipulation performance vs. PHP

开发者 https://www.devze.com 2023-01-30 23:55 出处:网络
Im building a custom jquery modal box that loads an external html template file that contains variables that need to be replaced.For instance: [user-name]

Im building a custom jquery modal box that loads an external html template file that contains variables that need to be replaced. For instance: [user-name]

I know I have 2 options for modifying the template file:

  • use find and replace in jquery
  • process the template server side and sim开发者_开发技巧ply send the result to jquery

From a user performance stand point, which would be faster?


From a user point of view it would be faster to use jquery . you don't loose time by sending and reciveing data from the server


Not having any details about why you're asking, I would say that it probably doesn't matter.

0

精彩评论

暂无评论...
验证码 换一张
取 消