标签: edit

textareas中的内容设置为使用nicEdit不更新以反映用户更改

因为我的英语水平低而接受我的道歉

我用jQuery加载一个页面,我在那个页面使用nicEdit,然后用jQuery将数据发布到另一个页面.但它只是发送空值而不是用户在编辑器中写入的内容(如果我为我的文本区域定义默认值,它只发送默认值而不是用户写的文本).问题是什么,解决方案是什么?

谢谢.


更新在阅读了这篇相关文章及其最后的评论并阅读其他文章后,我发现在提交表格之前必须使用这种方式:

nicEditors.findEditor('textarea_id').saveContent();
Run Code Online (Sandbox Code Playgroud)

为此,我使用jquery选择任何textarea并调用.each()jquery函数.例如 :

$('textarea').each(function(){
   var IDOfThisTextArea =   $(this).attr('id');
   nicEditors.findEditor(IDOfThisTextArea).saveContent()
});
Run Code Online (Sandbox Code Playgroud)

这对于事先创建的textarea来说很好.但是我有一些通过jQuery动态创建的textarea,findEditor()上面的函数没有找到那些并且没有调用saveContent()那些.

对于这个问题你提供什么??????

TNX

jquery edit nicedit

7
推荐指数
1
解决办法
7188
查看次数

Rails 3 - best_in_place编辑

希望是一个简单的答案; 我正在使用gem best_in_place,效果很好.我正在尝试使用以下方法找出如何创建下拉菜单:

:type => :select, :collection => []
Run Code Online (Sandbox Code Playgroud)

我想要做的是传递从我的用户模型输入的名称列表.

有什么想法怎么做?我可以将它与collection_select混合使用吗?

jquery ruby-on-rails edit best-in-place

7
推荐指数
1
解决办法
2974
查看次数

OSStatus错误 - 12780时调用insertTimeRange:ofTrack:atTime:错误:AVMutableCompositionTrack第二次

首先,我要说我喜欢这个论坛,它帮助了我很多时间.我有一个问题,我无法在任何地方找到答案,所以这是我的第一个问题.

我的问题是:

我有一个由AVPlayerItem表示的视频,用户可以使用cutBefore按钮编辑视频开始时间,该按钮将视频剪切到滑块的左侧

负责剪切视频的方法如下:

- (void)CutBeforeAction { 

AVMutableComposition *composition = [AVMutableComposition composition];

// Get the audio and video tracks of the video
AVMutableCompositionTrack *compositionVideoTrack = [composition addMutableTrackWithMediaType:AVMediaTypeVideo preferredTrackID:kCMPersistentTrackID_Invalid];
AVMutableCompositionTrack *compositionAudioTrack = [composition addMutableTrackWithMediaType:AVMediaTypeAudio preferredTrackID:kCMPersistentTrackID_Invalid];

// Calculate the new duration
CMTime currStartTime = _player.currentItem.currentTime;
CMTime endTime = _player.currentItem.duration;
CMTimeRange range = CMTimeRangeFromTimeToTime(currStartTime, endTime);

// Insert the new duration to the tracks
NSError *error = nil;
[compositionVideoTrack insertTimeRange:range 
                               ofTrack:[[_player.currentItem.asset tracksWithMediaType:AVMediaTypeVideo] objectAtIndex:0]
                                atTime:kCMTimeZero
                                 error:&error];

[compositionAudioTrack insertTimeRange:range 
                               ofTrack:[[_player.currentItem.asset tracksWithMediaType:AVMediaTypeAudio] objectAtIndex:0]
                                atTime:kCMTimeZero
                                 error:&error];
// Create …
Run Code Online (Sandbox Code Playgroud)

iphone video edit

7
推荐指数
1
解决办法
3070
查看次数

用PHP编辑.htaccess

我有一个.htaccess将域映射到文件夹.

RewriteEngine On
RewriteBase /

# redirect mapped domain
ReWriteCond %{HTTP_HOST} joshblease.uk.to
ReWriteCond %{REQUEST_URI} !gme-index/
ReWriteRule ^(.*)$ gme-index/$1 [L]
Run Code Online (Sandbox Code Playgroud)

有没有办法使用PHP编辑/添加额外的域映射到文件?

简单地说,我想获取.htaccess文件的内容并使用PHP脚本添加到它们中.

php mapping dns .htaccess edit

7
推荐指数
1
解决办法
2万
查看次数

如何将缩进从2个空格转换为4个空格

可能重复:
HOWTO:修复Python缩进

我有Python库,其中只使用了2个空格缩进.我需要自动方式将所有文件转换为4个空格缩进.有没有任何工具/脚本/编辑器?

Plz不建议使用Emacs.

python automation edit indentation

7
推荐指数
1
解决办法
6497
查看次数

如何获得评论编辑历史记录

在Facebook我们现在可以编辑我们的评论,我们可以通过点击编辑的按钮看到编辑历史.

但我无法通过FQL或图形api获取编辑历史记录,是否有人知道如何获取它?

history comments facebook edit

7
推荐指数
0
解决办法
277
查看次数

iOS - 如何实现裁剪图像,如默认相册?

iPhone相册中的默认裁剪功能

在此输入图像描述

有谁知道如何实现这个?我想在点按" 使用"按钮之前裁剪它.

在此输入图像描述

camera image edit crop ios

7
推荐指数
2
解决办法
1万
查看次数

编辑woocommerce登录注册页面

我在电子商务网站上使用woocommerce.我想在Login Regiser页面中再添加一个字段.在此页面上有三个注册字段(电子邮件,密码和重新输入密码),我想再添加一个电话号码字段.

有谁能够帮我 ?在此先感谢 http://wordpress.org/plugins/woocommerce/

login edit registration woocommerce

7
推荐指数
2
解决办法
3万
查看次数

将文件直接传递给nano会因sighup或sigterm而失败

我想在我的服务器上搜索特定文件,并在nano内直接编辑它.

我试过这样,但它不会工作

find -name file.php | xargs nano $1
Run Code Online (Sandbox Code Playgroud)

找到该文件,但它不会那样工作

Received SIGHUP or SIGTERM
Run Code Online (Sandbox Code Playgroud)

该如何做到这一点?

search edit find nano

7
推荐指数
2
解决办法
4180
查看次数

如何在iOS中的文本选择编辑菜单中添加自定义操作?

我需要在编辑菜单中添加一个自定义操作,当用户在iOS中的UITextView中选择一些文本时,该菜单会弹出.
我该怎么做呢?

menu edit uitextview ios swift

7
推荐指数
1
解决办法
4158
查看次数