Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
string1我有一个模板,我要传递string2给它。
string1
string2
然后我想显示传递的变量,string1string2.zip但问题是它被读取就好像我想从 string2 获取 zip 属性而不是将其显示为单独的文本。
string1string2.zip
创建的错误是 AttributeError: 'str' object has no attribute 'zip'
AttributeError: 'str' object has no attribute 'zip'
有什么办法吗?
不知道为什么这被否决了..
尝试这个:
$(string1)$(string2).zip