我想改变特定占位符的颜色.我正在为我的项目使用很多输入字段,问题是在某些部分我需要占位符的灰色,在某些部分我需要占位符的白色.我搜索了这个目的并找到了这个解决方案.
::-webkit-input-placeholder { /* WebKit, Blink, Edge */
color: #909;
}
:-moz-placeholder { /* Mozilla Firefox 4 to 18 */
color: #909;
opacity: 1;
}
::-moz-placeholder { /* Mozilla Firefox 19+ */
color: #909;
opacity: 1;
}
:-ms-input-placeholder { /* Internet Explorer 10-11 */
color: #909;
}
Run Code Online (Sandbox Code Playgroud)
但是这个代码是在所有输入占位符上实现的,我不需要所有输入占位符都是相同的颜色.所以任何人都可以帮助我.提前致谢.
我希望在发布数据后得到响应,但它失败了.我想创建一个登录系统,我已成功将数据提交到php文件,一切正常,我想从同一个函数得到响应,但我不知道问题出在哪里.
这是Java函数:
public class PostDataGetRes extends AsyncTask<String, String, String> {
protected void onPreExecute() {
super.onPreExecute();
}
@Override
protected String doInBackground(String... strings) {
try {
postRData();
} catch (NullPointerException e) {
e.printStackTrace();
} catch (Exception e) {
e.printStackTrace();
}
return null;
}
@Override
protected void onPostExecute(String lenghtOfFile) {
// do stuff after posting data
}
}
public void postRData() {
String result = "";
InputStream isr = null;
final String email = editEmail.getText().toString();
final String pass = editPass.getText().toString();
// Create a …Run Code Online (Sandbox Code Playgroud) 我是laravel的新手,我正在尝试将视图中的数据传递给控制器,但却出现了一些错误.我已经搜索但没有得到我怎么能解决这个问题.请查看我的代码并告诉我哪里错了?
echo Form::open(array( 'method' => 'post','action' => 'DemoController@savess'));
echo Form::label('name', 'Name');
echo Form::text('name');
echo Form::label('email', 'E-Mail Address');
echo Form::text('email');
echo Form::close();
Run Code Online (Sandbox Code Playgroud)
namespace App\Http\Controllers;
use Illuminate\Http\Request;
class DemoController extends Controller {
/*
|--------------------------------------------------------------------------
| Welcome Controller
|--------------------------------------------------------------------------
|
| This controller renders the "marketing page" for the application and
| is configured to only allow guests. Like most of the other sample
| controllers, you are free to modify or remove it as you desire.
|
*/
/**
* …Run Code Online (Sandbox Code Playgroud) 我想使用javascript在所有输入字段上添加readonly属性.我已使用此方法完成单输入字段,$('#someid').prop('readonly', true);但我想在编辑模式下添加到所有输入字段.
<div class="form-group">
<label for="Barcode">Barcode: </label>
<input name="Barcode" id="Barcode" class="form-control" value="<?=$data['Barcode']?>" placeholder="Barcode">
</div>
<div class="form-group">
<label for="ApplicantName">ApplicantName: </label>
<input name="ApplicantName" id="ApplicantName" class="form-control" value="<?=$data['ApplicantName']?>" placeholder="ApplicantName">
</div>
<div class="form-group">
<label for="SubBarcode">Reference No: </label>
<input name="SubBarcode" id="SubBarcode" class="form-control" value="<?=$data['SubBarcode']?>" placeholder="Reference No">
</div>
<div class="form-group">
<label for="ClientName">Client Name: </label>
<input name="ClientName" id="ClientName" class="form-control" value="<?=$data['ClientName']?>" placeholder="Client Name">
</div>
<div class="form-group">
<label for="ClientRefNo">Client Reference No: </label>
<input name="ClientRefNo" id="ClientRefNo" class="form-control" value="<?=$data['ClientRefNo']?>" placeholder="Client Reference No">
</div>
<div class="form-group">
<label for="DateOfBirth">Date Of Birth: </label> …Run Code Online (Sandbox Code Playgroud) 我想在mysql中获取最后一行特定的id.假设我有一个表用户产品
userProducts
id | user_id | products
1 | 12| Mouse
2 | 12| Keyboard
3 | 12| Laptop
4 | 12| Headphone
5 | 12| Webcame
Run Code Online (Sandbox Code Playgroud)
我想获得最后一行Webcame user_id=12.请指导我如何为此自定义此查询.
select * from userProducts where user_id = 12
Run Code Online (Sandbox Code Playgroud)