Screen-shots of fields to be removed
Fields to be removed are following
1. Version [of product]
2. Hardware
3. OS
You need to change on:
Path -> bugzilla\template\en\default\bug\create
File -> create.html.tmpl
First I deleted Perl code and left just the HTML as below and it workded:
<input type="hidden" name="version" size="6" maxlength="6" value="unspecified">
<input type="hidden" name="rep_platform" size="6" maxlength="6" value="PC">
<input type="hidden" name="op_sys" size="6" maxlength="6" value="Windows XP">
Related
Here is my Code and so have many fields like this :
<input type="text" pInputText class="form-control" name="companyName" [(ngModel)]="company.Name" required #companyName="ngModel"
/>
<label>Company Name</label>
<p class="ui-message ui-messages-error ui-corner-all" *ngIf="(!companyName.valid && companyName.touched)">
Company Name is required
</p>
Instead of defining separate message for all mandatory/invalid fields, can't I use single message with place holder for field name? So whenever I want to change message, I can manage this with single line change.
e.g. "${field} is required, ${field} is not valid etc."
please give me a example if this can do
The first solution that crossed my mind was just wrap the error messages in a function:
var displayError = (field) => `${filed} is required`;
And on the HTML
<input type="text" pInputText class="form-control" name="companyName" [(ngModel)]="company.Name" required #companyName="ngModel"/>
<label>Company Name</label>
<p class="ui-message ui-messages-error ui-corner-all" *ngIf="(!companyName.valid && companyName.touched)">
{{ displayError('Company name') }}
</p>
I still have doubt in using ng-mask, I went through most of the web pages for it to work but it still remains the same. And many people told to use it with input tag of angularjs, after doing so Im not able to mask the input.Or am I making mistake please somebody correct me and give the clarity of using the ng-mask.
<input type="tel" name="phoneno" maxlength=13 ng-model="phone.number" ng-mask="(999)999-9999"/>
</div>
<button class="button2" ng-click="home()">Back</button>      
<button class="button3" ng-click="addphone()">Add</button>
Download the ngMask.min.js from net
Call the ngMask.min.js before app.js and Include app.js module
var yourApp= angular.module("yourApp", [
'ngMask'
]);
HTML :
<input type="tel" name="phoneno" maxlength=13 ng-model="phone.number" mask="(999)999-9999" />
Below code is working for me.
I think you should use data-on attribute like below
<input type="text" class="form-control input-small" data-ng-model="zipcode" placeholder="Enter the zip code" data-ng-mask="#####-###" data-on="keyup">
// 2. Add ngMask module dependency to your app.
angular.module('yourApp', ['ngMask']);
<!-- 1. Add ngMask plugin after your AngularJS. -->
<script src="angular.min.js"></script>
<script src='ngMask.min.js'></script>
<!-- 3. Use the avaiable patterns to create your mask. Set the mask attribute. -->
<input type='text' ng-model='maskModel' mask='39/19/9999' />
<!-- 4. Adjust your mask options. -->
<input type='text' ng-model='maskModel' ng-value='0/3/9' mask='3/9?' mask-repeat='2' mask-restrict='accept' mask-clean='true' mask-validate='false' mask-limit='false' />
source: https://github.com/candreoliveira/ngMask/blob/master/README.md
Use ui-mask instead:
<div class="form-group">
<label for="birth-date">Date of birth</label>
<input type="text"
class="form-control"
id="birth-date"
ng-model="formData.date_of_birth"
ng-value="formData.date_of_birth"
ui-mask="99.99.9999"
ui-mask-placeholder
ui-mask-placeholder-char="_"
>
</div>
https://github.com/angular-ui/ui-mask
I am trying to do some math with user inputs.
I have this basic objets to start with
$scope.shape =
{id: 1, cx: 0, cy: 0, result: 0}
;
And the user can type the value of cx and cy into fields;
<input ng-model="shape.cx" type="text" class="form-control" id="cx">
<input ng-model="shape.cy" type="text" class="form-control" id="cy">
I want to multiply the 2 values cx and cy and show the result in another input.
<input type="text" class="form-control" id="A" ng-model="shape.cx * shape.cy">
This is working, I can see the the result in the field but I get an error;
Error: [ngModel:nonassign]
I would also like to asign this result to shape.result.
How can I set the value of shape.result to be shape.cx*shape.cy
See here it could be done like this :
SCENARIO 1 : Result on Button Click : (Procedural Approach)
<input ng-model="shape.cx" type="text" class="form-control" id="cx">
<input ng-model="shape.cy" type="text" class="form-control" id="cy">
<input type="button" class="form-control" ng-click="calculate()">
<input type="text" class="form-control" id="A" ng-model="shape.result">
$scope.calculate = function(){
$scope.shape.result = parseInt($scope.shape.cx) * parseInt($scope.shape.cy);
}
SCENARIO 2 : As soon as Value Changes in text boxes : (Direct Approach)
<input ng-model="shape.cx" type="text" class="form-control" id="cx">
<input ng-model="shape.cy" type="text" class="form-control" id="cy">
<input type="text" class="form-control" id="A" ng-model="parseInt(shape.cx) * parseInt(shape.cy)">
SCENARIO 3 : Using $watch : (Procedural Approach)
<input ng-model="shape.cx" type="text" class="form-control" id="cx">
<input ng-model="shape.cy" type="text" class="form-control" id="cy">
<input type="text" class="form-control" id="A" ng-model="shape.result">
$scope.$watch(function (){
$scope.shape.result = parseInt($scope.shape.cx) * parseInt($scope.shape.cy);
});
Note :
Scenario 3 is using $watch hence it should be not used untill and unless you're in real need of it.
Scenario 1 is best suited to you I think as it will make your concept.
Scenario 2 is a direct approach hence should be used after gaining some knowledge as well as experience(But it's short & best within 3 scenatios). It's a reference from #tapos answer
Thanks & Cheers
Well you need to watch for cy and cx changes and do the calculation when it change.
$scope.$watch('shape.cx', function() {
$scope.shape.result = $scope.shape.cx * $scope.shape.cy;
});
Example fiddle: http://jsfiddle.net/ccmf07k2/
Every language input field is string when a user enter any number in text box it is string
<input ng-model="shape.cx" type="text" class="form-control" id="cx">
<input ng-model="shape.cy" type="text" class="form-control" id="cy">
so you need some work in your result box ix
<input type="text" class="form-control" id="A" ng-model="parseInt(shape.cx) * parseInt(shape.cy)">
then you get your appropriate result
I couldn't find any similar questions (most dealt with broken form posts) but this is not the case.
I have a paypal form that works flawlessly on desktop/laptop. On mobile devices I successfully get to paypal but there is nothing in the order summary, as if nothing got posted to paypal. A variable dump shows all form variables are in place, so I'm quite confused.
Here is the form I submit:
<form action="https://www.paypal.com/cgi-bin/webscr" method="post" id="myRegister">
<input type="hidden" name="cmd" value="_xclick">
<input type="hidden" name="business" value="service#obscured.com">
<input type="hidden" name="item_name" value="Some description.">
<input type="hidden" name="amount" value="5.00">
<input type="hidden" name="no_shipping" value="0">
<input type="hidden" name="no_note" value="1">
<input type="hidden" name="currency_code" value="USD">
<input type="hidden" name="lc" value="US">
<input type="hidden" name="bn" value="PP-BuyNowBF">
<input type="hidden" name="item_number" value="1248" />
<input type="hidden" name="cbt" value="Click This Button To Register." />
<input type="hidden" name="return" value="http://mydomain/redirect.cfm" />
</form>
And that works on Desktop. I am just trying to get it work within a phone browser at the moment. I'll deal with the Paypal phone app at another time, if needed.
Any help appreciated.
Edit: This is also happening with PayPal hosted Buy It Now buttons as well.
Your code works fine for me on mobile, I can see the order details by tapping the "My total". The details are hidden at the first place though, I have to tap to make it show, seems it's designed this way
Within Android browser settings, clear setting for individual websites: Settings > Content Settings > Website Settings. Select paypal.com. Apparently there was a issue that was not resolved just by clearing the browser cache.
I have a PresentationsController which handles some POST action form. In this form I have data related to Presentation such as:
<input name="data[Presentation][title]" class="init-focus span4" type="text" id="PresentationTitle" required="required">
and those fields are handled correctly by controller. But PresentationModel hasMany Subject. So I want to include some presentation subjects in form. I did it like this:
<input name="data[Subject][0][subject]" disabled="disabled" class="subject" maxlength="255" type="text" id="Subject0Subject" required="required">
<input name="data[Subject][1][subject]" disabled="disabled" class="subject" maxlength="255" type="text" id="Subject0Subject" required="required">
But those data are not handled by Cake - I tried var_dump($this->request->data) in Controller but they are missing... for some reason Cake just ignores those data...
I am generating inputs dynamicalyy with jquery but it inputs are added correctly to form - I can see them in my browser html elements viewer:
<input name="data[Subject][0][subject]" maxlength="255" type="text" id="Subject0Subject" required="required">
<input name="data[Subject][1][subject]" disabled="disabled" class="subject" maxlength="255" type="text" id="Subject0Subject" required="required">
The above is what I view in html elements viewer - the first input is added "inline" from php and second is added dynamically with jquery. And only the first one is visible after POST.
When you set an input to disabled="disabled" it is NOT submitted. That goes for normal HTML and is not something CakePHP specific.
According to W3Schools.com:
Disabled elements in a form will not be submitted.