我正在使用CkEditor,因此我为textarea设置了4尺寸。
CKEDITOR.editorConfig = function( config ) {
config.height = '842px';
config.width = '595px';
};
Run Code Online (Sandbox Code Playgroud)
HTML:
<textarea name="Editor" class="ckeditor" id="aboutme"></textarea>
Run Code Online (Sandbox Code Playgroud)
Javascript:
var editor = CKEDITOR.instances.aboutme;
var edata = editor.getData();
var replaced_text = edata.replace(/(\[##.+?##\])/g, '<span style="background-color:yellow"><strong>$1</strong></span>');
editor.setData(replaced_text);
Run Code Online (Sandbox Code Playgroud)
我的问题:
如果textarea有2张a4纸,我想在textarea中的第一张和第二张a4纸之间添加红色下划线。
我试图替换以执行此操作,但是我对javascript中ckeditor的a4纸不了解。
我想在842px(a4纸张大小)后加上红色下划线
如何在javascript中842px之后加上红色下划线?
任何帮助将不胜感激。
谢谢。
代码:
var doc = new jsPDF('p', 'mm', [300, 210]);
doc.fromHTML(text, 15, 15, {
'width': 175,
});
doc.text(10, HEIGHT, 'What should be height so it does not overlap with previous text');
Run Code Online (Sandbox Code Playgroud)
这是我的代码,但两个文本相互重叠?有什么方法可以知道 HEIGHT 的值(知道前面的文本在哪里结束)以使两个不重叠?text html 不是静态的,它会改变。
我制作了一个显示SVG元素(嵌入HTML)的网站,并希望允许用户<circle>通过用鼠标或手指在其上拖动来连接其中的点(元素)。
通过监听mousedown和mouseover事件并向lineSVG中添加元素,可以在桌面上完美地工作。
我加了听众touchstart,touchmove,touchend和touchcancel,但我遇到了问题。似乎touchmove从来没有在Android手机上的Google Chrome和Android平板电脑上的Google Chrome上触发过,只有当我松开手指时才会触发。
编辑:这是我的小提琴代码:http : //jsfiddle.net/s5vcfzbq/您可以用鼠标从一个圆圈拖动到另一个圆圈来连接它们,但是在触摸屏上不起作用。
我有一个interface实现JPARepository,有三个方法,其中一个是自定义@Query.
public interface PersonRepository extends JpaRepository<Person, Long> {
List<Person> getPersonBycountryCode(String countryCode);
List<Person> findByCountryCodeAndCity(String string,String city);
@Query(value = "SELECT person.firstName as firstName, person.lastName as lastName, person.countryCode as country, person.city as city,"
+ " SQRT(POWER((69.1 * (person.age - :age )) , 2 )"
+ " + POWER((53 * (person.experience - :experience )), 2)) as eligibility"
+ " FROM Person person"
+ " ORDER BY eligibility ASC")
List<PersonDetailsDto> findPersonDetailsByEligibility(
@Param("age") BigDecimal age,
@Param("experience") BigDecimal experience,
Pageable pageable …Run Code Online (Sandbox Code Playgroud) 我刚刚创建了一个div.White-space: Normal当我输入内容时,我给了一个自动换行功能.此功能适用于Chrome,Opera和Safari浏览器.但这些话并没有包含在Mozilla Firefox和Edge浏览器中.我也试过这个Word-wrap: break-word功能.这也行不通.请给我一个解决方案.
<div class = "list-name-field" id = "SAVE_LIST" style = "white-space: normal; width: 240px; min-height: 35px; border-radius: 3px; margin-left: auto; margin-right: auto; background-color: #ccc; margin-top: 5px; " contenteditable = "true" data-placeholder = "Add a List..."></div> Run Code Online (Sandbox Code Playgroud)
我想根据屏幕分辨率编写媒体查询。我的屏幕分辨率高度是768。为此我写了以下媒体查询:
@media(min-height:768px) and (max-height:850px) {
.video-contain{
margin-top:110px;
}
}
Run Code Online (Sandbox Code Playgroud)
我上面的媒体查询不起作用.margin-top之前没有设置。我写了基于屏幕分辨率而不是浏览器高度的媒体查询。
我正在使用允许多个小数点的类型 number 输入,所以我尝试使用正则表达式不允许超过一个小数点但即使在使用正则表达式后我也面临同样的问题谁能告诉我如何只允许ionic1 中类型数字输入中的一个小数点
网址:
<input stopccp focus-me class="inputContainer trade_input" type="number" name="" ng-model="vm.total_amount[$index]" ng-change="vm.onTotalCost()" limit-char limit="5" ng-keyup="vm.decimalcheck(vm.total_amount[$index])" >
Run Code Online (Sandbox Code Playgroud)
函数中的正则表达式:
function decimalcheck (element) {
$log.log('decimalcheck got called', element);
var regex = /\d*\.?\d?/g;
return regex.exec(element);
}
Run Code Online (Sandbox Code Playgroud) <body style="background-color: paleturquoise">
<h2 style="color: red">Duke's soccer League: Home Page<br/></h2>
<ul style="list-style-type: circle">
<li style="font-size: larger"><a href="league_list.in">All Leagues list</a></li>
<li style="font-size: larger">Register for a League (TBA)<br/><br/></li>
</ul>
<h2 style="color: red">League Administrator</h2>
<ul style="list-style-type: square">
<li style="font-size: larger"><a href="add_league.in">Add a new League (TBA)</a></li>
<img src="C:\Users\VIRK\Desktop\66.jpg" width="400" height="400" ></img>
</ul>
</body>
Run Code Online (Sandbox Code Playgroud)
我目前正在使用JSP,我尝试使用这个html代码在NetBeans IDE 7.0上创建一个网页,但是当我构建并运行页面时,代码中没有错误但是图像没有显示在浏览器中.
编辑:

在这里,我给出了NetBeans IDE的屏幕截图,您可以在其中看到图像存在于Web-INF文件夹和index.jsp页面中,我"/"在图像名称之前尝试过,但它不起作用.我的项目的确切路径是C:\ Users\VIRK\Documents\NetBeansProjects\practiceJSP.
<img src="/66.jpg" width="400" height="400" ></img>
Run Code Online (Sandbox Code Playgroud) I have below result (Run Code Snippet Button below), I don't need border around each cell separately I need a simple table like:
table td{
border:1px solid #000000;
}Run Code Online (Sandbox Code Playgroud)
<table class="table table-bordered">
<thead>
<tr>
<th>Sr No</th>
<th>Product Name</th>
<th>Quantity</th>
<th>Add</th>
</tr>
</thead>
<tbody class="allign-center">
<tr>
<td>1</td>
<td class="proname">MARHABA SAFOOF TABKHIR</td>
<td><input class="qty" type="number"></td>
<td><button class="btn btn-xs btn-success" onclick=""><i class="fa fa-arrow-right"></i>Add</button></td>
</tr>
<tr>
<td>2</td>
<td class="proname">MARHABA JAWARISH SHAHI AMBRI</td>
<td><input class="qty" type="number"></td>
<td><button class="btn btn-xs btn-success" onclick=""><i class="fa fa-arrow-right"></i>Add</button></td>
</tr> …Run Code Online (Sandbox Code Playgroud).normal-text我需要在使用该类的元素之前显示引导字形:我正在尝试以下操作,但它显示的是代码而不是图标。
.normal-text{
border-left-width: 1px !important;
font-size: 110% !important;
color: #100cce;
font-family: 'Book Antiqua';
}
.normal-text::after{
content: '<span class="glyphicon glyphicon-pencil"></span>'
}
Run Code Online (Sandbox Code Playgroud)
<blockquote class="normal-text"> Some Text </blockquote>Run Code Online (Sandbox Code Playgroud)
请提供这方面的帮助。
html ×9
javascript ×5
css ×4
angularjs ×1
blockquote ×1
ckeditor ×1
image ×1
java ×1
jpa ×1
jquery ×1
jsp ×1
jspdf ×1
regex ×1
spring ×1
spring-data ×1
svg ×1
touchscreen ×1