Discussions
Stay up-to-date with the latest news from NetSuite. You’ll be in the know about how to connect with peers and take your business to new heights at our virtual, in-person, on demand events, and much more.
New AI Community Guidelines. Please review and follow them to ensure AI use stays safe, accurate, and compliant.
Please note that on Saturday, April 18, 2026, at 8:00 PM Pacific Time, our Case Management System will undergo a scheduled maintenance for approximately 15 minutes. During this time, case creation via SuiteAnswers will be unavailable and inbound calls will be routed to Customer Service.
file exists?
Is there any way in a template to see if a particular file exists?
Some products in my site have specific stylesheets, and rather than have a different template for products with and without custom stylesheets, I'd like to have something in the template's "add to <head>" like:
&lt;link rel="stylesheet" type="text/css" href="/css/products/&lt;%=getCurrentAttribute('item','itemid')%&gt;.css"&gt;...but of course, if there is no stylesheet, I don't want to refer to it and generate a 404 error every time someone views such a product.
So ideally, I could (pseudo-code, and please excuse the nested <% %> -- it's just there to make the point):
0