Hot answers tagged

9

In your javascript controller, you can get the component using the find method and then get the attribute value of the comonent using the get method.. component.find("categoryPicklist").get("v.value"); Refer this Trailhead module for more details


9

The code in the documentation should work fine, you just need to make sure the required variables all get set properly before executing the API calls. This piece of code is using the RequestParameter function to set @sid, @jid, @listid and @batchid from a form. You would want to create a form that POSTs to a page that contains this AMPscript. SET @sid = ...


7

@TCassa, your approach appears correct. I've taken this approach many time before. I suspect it is just something minor in your code like a syntax issue or undefined variable. Suggestion: I've started using a new approach in this scenario by using the IIF() function. This approach allows me to place the AMPScript code inline with my HTML. <input type=...


6

To display a message on your page you can add <apex:messages/> as suggested in the comments. And to stop execution you need to put the code that you don't want to execute if Account was not found inside your if(lstAccount.size() > 0){ ... } block. You can also add a return statement like that: if(lstAccount.size() > 0){ AccName = lstAccount[...


5

You can use localStorage or sessionStorage, available in 94% of all browsers globally, to unobtrusively store and load data on demand. Save formats may not be compatible across changes to the page, though, so some caution. And, of course, there is a 5MB limit on most systems, so you may have to choose what to save. You need just two functions. One that ...


5

Here is a link that explains how html treats buttons and difference between <button> and <input type="button"> Form buttons created by <button> element are treated as form submitter so they refresh page. Browsers treat <button id="upload-button" >Upload</button> as <button id="upload-button" type="submit" >Upload<...


5

This is not a salesforce question. This is a question purely based on web technology. The fast answer: your web form has an attribute called target, this can be self or blank or ... . self will display in the same frame. You can also develop javascript that takes the action and handles it inside javascript. this can be done with an eventhandler that uses ...


4

As this looks like jQueryUI's datepicker, the JavaScript below reflects that assumption. The <apex:inputField> will render an input element. You don't need to wrap it with another one. The salesforce input element will be rendered to the page and have a dynamically generated ID value based on its location in the page hierarchy and will end with the ...


4

There's no auto-numbering in SFMC. You have a few options: You can assign them a GUID with the NewID() SQL function in a Query Activity. You can reference the hidden _CustomObjectKey column in a Data Extension. It's a unique number assigned to each row. It is not always sequential and does not start at 1. You can use a ranking function in SQL to ...


4

As per your situation, I'd recommend using DE manager since it is really easy to implement. You'll need couple of things: 1) Setup the Data Extension in Salesforce Marketing Cloud with field that would match with your form page/iframe. 2) Details of your SFMC account and DE: _clientID - your account number _deExternalKey - the external key for the data ...


4

The best thing to do for your specific scenario is to 'hide' the lightning:inputField and add a lightning:input, similar to what Uwe Mentioned, however, you dont really need to do anything with the lightning:inputField, you will simply need it to load the data associated to it and to be able to Save the field value on form submission. For Example: <...


4

use reRender attribute on apex:commandButton here is a nice article Implementing Partial Page Updates with Command Links and Buttons where all required steps are listed First, create or identify the portion of the page that should be rerendered. To do this, wrap the tag in an <apex:outputPanel> tag, and give the output panel an id parameter. The ...


4

You could certainly create an expiring token to "time bomb" your page. The following steps should provide an outline: Add a field named Form_Token__c Text (32) Add a Time Based Workflow Rule to clear the value after 24 hours Update any triggers on your object (or add one if none exist) to set this token value Since I have been looking at how to generate a ...


3

Causeview is a third-party product built on top of the Salesforce platform to handle donation processing, and (as you can guess from the URI you are IFRAME-ing) their forms are not actually generated by Salesforce. The admin of the organization using Causeview will have created the form in the ActionPage Designer (inside of Salesforce). They have the ...


3

It could be a problem of access to the PreChat page. Try to add it to the Site Visualforce Pages of a public Site and give the right accesses to the page itself.


3

Try using a tag that doesn't need to live inside a form (like an outputLink), and adding actionSupport to call the UpdateABC method. Something like: <apex:outputLink> [link text here] <apex:actionSupport event="onclick" action="{!UpdateABC}"/> </apex:outputLink>


3

Is it possible to create an apex endpoint to which I can submit a form? Yes, that's one valid use of the @RestResource annotation. After all, a "REST Resource" is simply an HTTP endpoint like any other. Do I need to still use a force.com site to open up the endpoint? If so, does that introduce any limits or considerations. If you want to have anonymous ...


3

There are 2 ways that we use to pass user information to Landing Pages: Option 1: QueryParameter In Email: %%[VAR @email,@name,@landingpage Set @email = 'email@example.com' Set @name = 'Test' Set @landingpage = Concat('https://pub.exacttarget.com/landingpage?email=',@email,'&name=',@name) ]%% <a href = "%%=RedirectTo(@landingpage)=%%">Click ...


3

Pardot: June 29, 2017 Pardot Automation Rules now have ‘repeat’ functionality. This new feature allows the User to determine if an Automation Rule should be allowed to match a prospect more than once. Source: Pardot blog | Automation Rule Repeat Functionality


3

You cannot directly control the tab order in Lightning any longer. This is documented in the Known Issue. Please don't use tabindex values aside form 0 and -1. If you want to change the tab order on the page, change the dom order. Original Answer Set the tabindex parameter for each element, such as: <lightning:input tabindex="10" ... /> <...


3

Yes, you can do this, just make sure you cancel the default action: <apex:actionFunction name="doAction" action="{!someMethod}" /> <button onclick="doAction(); return false;">Do Action!</button> If you don't include a reRender attribute, it behaves mostly like a normal full-form submit, but if you do, it does a partial update of the page. ...


3

Welcome to SFSE! It looks like your standard controller is pointed to the Student__c Object, but all of your bindings are to the Contact object, like this <apex:inputField value="{! Contact.FirstName }"/> Instead, bind to your student object, like this <apex:inputField value="{! Student__c.FirstName }"/> Add as many fields as you need. Then,...


3

Unfortunately you can't specify columns that way with apex:pageblocksection, it's always left-to-right. You could just use one field set and just training people to put them into the field set in the desired left to right ordering. If that's not practical with apex you can take to field sets and combine them into a single array with the left-to-right ...


3

Another thought... You could store a secret key in a custom setting or custom metadata. When you generate a link, it will have an expiry timestamp parameter, a customer ID parameter and a hash parameter. The hash would be generated in Apex by appending the timestamp and the ID into one string, encrypting it with the secret key, generating a MD5 digest, and ...


3

You should probably update your post with your last comment, additionally, based on all your recent posts, it would seem you could benefit from following Trailhead modules, such as this one -> Injection Vulnerability Prevention Once you have gone through the module, if there is anything you still believes need clarification, dont hesitate to open a new post....


3

It's possible. You didn't specify where your custom form would reside, so I'm going to use a pair of CloudPages for a BARE-BONES (i.e., no fancy JS) example. We'll need: A page that contains the form A page that receives/processes the data A data extension that stores the data AMPscript Sites functions AMPscript Data Extension functions The form page <!...


3

You can break the date down into multiple fields which would allow you a bit more control over the format. For example, you could use a select input for the month and day and then have use a text input for the year. The layout of those fields would be stacked, but you would have more control over the data captured.


3

You don’t need the %% signs inside of an AMPscript block. This is the correct synthax: %%[ VAR @SubscriberKey, @EmailAddress set @EmailAddress = emailaddr set @SubscriberKey = Concat('TEST_', @EmailAddress) ]%% But you don't actually need the above block - you pass the value in a hidden form field if you just include the following inline AMPscript string ...


3

I'm not sure about the "why" your problem happens, but I would try solving it by narrowing the scope of the rerender, e.g. try to rerender a panel around your <table> element: <apex:page controller="MyController"> <apex:form id="myForm"> <apex:outputPanel> <apex:inputText value=&...


2

You can build your own set of SelectOption objects in your controller and set the isDisabled flag to true for the times that have already been booked. You would make the value strings match the picklist values. The Visualforce apex:selections tag links those options up to the input field. This of course assumes that you have some booking data objects to ...


Only top voted, non community-wiki answers of a minimum length are eligible